diff options
Diffstat (limited to 'nix/lib/mkSystem.nix')
| -rw-r--r-- | nix/lib/mkSystem.nix | 85 |
1 files changed, 45 insertions, 40 deletions
diff --git a/nix/lib/mkSystem.nix b/nix/lib/mkSystem.nix index c069a3f..ba9a46a 100644 --- a/nix/lib/mkSystem.nix +++ b/nix/lib/mkSystem.nix @@ -28,48 +28,53 @@ in systemFunc rec { inherit system; - modules = [ - # Allow unfree packages. - { nixpkgs.config.allowUnfree = true; } + modules = + [ + # Allow unfree packages. + { nixpkgs.config.allowUnfree = true; } - # Add overlays - { nixpkgs.overlays = overlays; } + # Add overlays + { nixpkgs.overlays = overlays; } - inputs.disko.nixosModules.disko - inputs.agenix.nixosModules.default + machineConfig + userOSConfig + home-manager.home-manager - machineConfig - userOSConfig - home-manager.home-manager - { - home-manager.useGlobalPkgs = true; - home-manager.useUserPackages = true; - home-manager.sharedModules = [ - inputs.agenix.homeManagerModules.default - ]; - home-manager.users.${user} = import userHMConfig { - inherit - self - inputs - darwin - systemName - ; - }; - home-manager.extraSpecialArgs = { - inherit self inputs; - configPath = "${self}/configs/users/${user}"; - }; - } + inputs.agenix.nixosModules.default + ] + ++ nixpkgs.lib.optional (!darwin) inputs.disko.nixosModules.disko + ++ [ + { + # https://github.com/nix-darwin/nix-darwin/issues/1339 + ids.gids.nixbld = 30000; + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.sharedModules = [ + inputs.agenix.homeManagerModules.default + ]; + home-manager.users.${user} = import userHMConfig { + inherit + self + inputs + darwin + systemName + ; + }; + home-manager.extraSpecialArgs = { + inherit self inputs; + configPath = "${self}/configs/users/${user}"; + }; + } - # We expose some extra arguments so that our modules can parameterize - # better based on these values. - { - config._module.args = { - currentSystem = system; - currentSystemName = systemName; - currentSystemUser = user; - inputs = inputs; - }; - } - ]; + # We expose some extra arguments so that our modules can parameterize + # better based on these values. + { + config._module.args = { + currentSystem = system; + currentSystemName = systemName; + currentSystemUser = user; + inputs = inputs; + }; + } + ]; } |
