blob: 9e7c69f2766d7ded20ef384d8dc10b704c307ce6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
{
config,
lib,
inputs,
...
}:
{
flake.nixosConfigurations =
let
hosts = builtins.attrNames (
lib.attrsets.filterAttrs (_: type: type == "directory") (builtins.readDir ./.)
);
mkNixosConfiguration = host: {
name = host;
value = inputs.nixpkgs.lib.nixosSystem {
modules = [
config.flake.modules.nixos."${host}"
];
};
};
in
builtins.listToAttrs (map mkNixosConfiguration hosts);
}
|