1
Fork 0
nixos-system-config/lib/hosts.nix

17 lines
347 B
Nix
Raw Normal View History

{ lib }:
{
mkHosts = {
modules,
nixpkgs,
inputs,
2024-07-25 21:32:55 +02:00
}: builtins.listToAttrs (builtins.map (host: {
name = host;
value = nixpkgs.lib.nixosSystem {
2024-07-25 21:32:55 +02:00
system = "x86_64-linux";
modules = modules ++ [ ../hosts/${host} ];
specialArgs = { inherit inputs; };
};
2024-07-25 21:32:55 +02:00
}) (lib.getDirsInDir ../hosts));
}