2023-11-14 18:29:14 +01:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
inputs,
|
|
|
|
...
|
|
|
|
}: let
|
2024-07-29 10:58:43 +02:00
|
|
|
_utils = import ../global/utils.nix {inherit lib;};
|
|
|
|
|
2024-03-24 14:02:03 +01:00
|
|
|
toSystem = name: {
|
|
|
|
role,
|
|
|
|
system,
|
|
|
|
}:
|
2024-06-26 19:30:41 +02:00
|
|
|
inputs.nixpkgs.lib.nixosSystem
|
|
|
|
{
|
2024-03-24 14:02:03 +01:00
|
|
|
inherit system;
|
|
|
|
|
2024-06-26 19:30:41 +02:00
|
|
|
modules = [
|
|
|
|
./${name}
|
|
|
|
./${name}/hardware-configuration.nix
|
|
|
|
../configs/${role}.nix
|
|
|
|
|
|
|
|
{networking.hostName = name;}
|
|
|
|
];
|
|
|
|
|
2024-07-29 10:58:43 +02:00
|
|
|
specialArgs = inputs // {inherit _utils;};
|
2024-01-18 15:15:14 +01:00
|
|
|
};
|
2024-06-26 19:30:41 +02:00
|
|
|
in {
|
|
|
|
flake.nixosConfigurations = lib.mapAttrs toSystem {
|
2024-03-24 14:02:03 +01:00
|
|
|
fuji = {
|
|
|
|
role = "desktop";
|
|
|
|
system = "x86_64-linux";
|
|
|
|
};
|
|
|
|
|
|
|
|
fuji-wsl = {
|
|
|
|
role = "client";
|
|
|
|
system = "x86_64-linux";
|
|
|
|
};
|
|
|
|
|
|
|
|
kilimandjaro = {
|
2024-08-17 19:17:41 +02:00
|
|
|
role = "laptop";
|
2024-03-24 14:02:03 +01:00
|
|
|
system = "x86_64-linux";
|
|
|
|
};
|
|
|
|
|
2024-09-01 17:32:09 +02:00
|
|
|
mottarone = {
|
|
|
|
role = "laptop";
|
|
|
|
system = "x86_64-linux";
|
|
|
|
};
|
|
|
|
|
2024-03-24 14:02:03 +01:00
|
|
|
etna = {
|
|
|
|
role = "server";
|
|
|
|
system = "x86_64-linux";
|
|
|
|
};
|
|
|
|
|
|
|
|
vesuvio = {
|
|
|
|
role = "server";
|
|
|
|
system = "aarch64-linux";
|
|
|
|
};
|
2023-11-14 18:29:14 +01:00
|
|
|
};
|
|
|
|
}
|