Cleanup darwin/linux split in mksystem

This commit is contained in:
2025-05-04 21:53:34 +02:00
parent 7cb0cbbe6a
commit 7db45cf96d
+14 -16
View File
@@ -54,24 +54,8 @@ in
];
};
})
(
if (!darwin)
then {
users.users.root.hashedPassword = builtins.readFile ../password/root;
users.users.${user} = {
isNormalUser = true;
hashedPassword = builtins.readFile ../password/${user};
extraGroups = ["wheel" "input" "docker" "audio" "mlocate" "libvirtd"];
};
networking.nameservers = ["1.1.1.1" "9.9.9.9"];
networking.resolvconf.extraConfig = "name_servers=\"1.1.1.1 9.9.9.9\"";
}
else {}
)
../hosts/${hostname}/hardware-configuration.nix
inputs.nix-index-database.nixosModules.nix-index
home-manager.home-manager
{
home-manager = {
@@ -89,6 +73,20 @@ in
};
}
]
++ nixpkgs.lib.optionals (!darwin)
[
inputs.nix-index-database.nixosModules.nix-index
{
users.users.root.hashedPassword = builtins.readFile ../password/root;
users.users.${user} = {
isNormalUser = true;
hashedPassword = builtins.readFile ../password/${user};
extraGroups = ["wheel" "input" "docker" "audio" "mlocate" "libvirtd"];
};
networking.nameservers = ["1.1.1.1" "9.9.9.9"];
networking.resolvconf.extraConfig = "name_servers=\"1.1.1.1 9.9.9.9\"";
}
]
++ nixpkgs.lib.optionals wsl [
inputs.nixos-wsl.nixosModules.wsl
({pkgs, ...}: {