Move modules out of config function

This commit is contained in:
Manuel Thalmann 2024-06-12 01:35:30 +02:00
parent 9fa02af3a3
commit ff48b4e3c6
2 changed files with 4 additions and 4 deletions

View file

@ -19,6 +19,7 @@
defaultMachine = {
system = "x86_64-linux";
modules = [ ];
config = { pkgs, ... }: {
dualBoot = false;
@ -26,7 +27,6 @@
keyMap = "us";
keyboardLayout = "us";
localeSettings = { };
modules = [ ];
users = { };
};
};
@ -102,7 +102,7 @@
) // {
nixosConfigurations =
builtins.mapAttrs (
hostname: { system, config }@machine: nixpkgs.lib.nixosSystem {
hostname: { system, config, modules }@machine: nixpkgs.lib.nixosSystem {
inherit system;
modules = [
@ -125,7 +125,7 @@
sops-nix.nixosModules.sops
./lib/configuration.nix
(tryFiles [ ./lib/machines/${hostname}.nix ] ./lib/hardware/base.nix)
];
] ++ modules;
})
machines;

View file

@ -5,7 +5,7 @@
./modules/my-users.nix
./modules/sddm.nix
./modules/unfree.nix
] ++ machine.modules;
];
config = {
system.stateVersion = "23.11";