roles: add role-based host composition in flake
- mkHost now takes a role list, roles resolve to ./roles/<name>.nix - roles/core.nix = shared baseline (modules/) - roles/k3s-server.nix = core + k3s (goyplex-vm) - roles/hermes.nix = core + hermes (hermes-vm) - host configuration.nix trimmed to hardware + boot + stateVersion - optional hosts/<name>/custom.nix loads last for per-host overrides - new hosts: one flake line + hosts/<name>/ dir
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
../../modules
|
||||
../../modules/k3s/k3s.nix
|
||||
];
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
../../modules/core
|
||||
../../modules/hermes
|
||||
];
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
../../modules
|
||||
];
|
||||
|
||||
boot.loader.grub.enable = true;
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
../../modules
|
||||
];
|
||||
|
||||
boot.loader.grub.enable = true;
|
||||
|
||||
Reference in New Issue
Block a user