mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-05-31 20:00:51 +02:00
b382999a70
refactor: Use hyphen(`-`) for variable names & folder names(except Python), replace all unserscore(`_`) with hyphen(`-`).
43 lines
1.1 KiB
Nix
43 lines
1.1 KiB
Nix
{
|
|
# NOTE: the args not used in this file CAN NOT be removed!
|
|
# because haumea pass argument lazily,
|
|
# and these arguments are used in the functions like `mylib.nixosSystem`, `mylib.colmenaSystem`, etc.
|
|
inputs,
|
|
lib,
|
|
mylib,
|
|
myvars,
|
|
system,
|
|
genSpecialArgs,
|
|
...
|
|
} @ args: let
|
|
# 星野 愛久愛海, Hoshino Akuamarin
|
|
name = "aquamarine";
|
|
tags = ["aqua" "homelab-network"];
|
|
ssh-user = "root";
|
|
|
|
modules = {
|
|
nixos-modules =
|
|
(map mylib.relativeToRoot [
|
|
# common
|
|
"secrets/nixos.nix"
|
|
"modules/nixos/server/server.nix"
|
|
"modules/nixos/server/proxmox-hardware-configuration.nix"
|
|
# host specific
|
|
"hosts/idols-${name}"
|
|
])
|
|
++ [
|
|
{modules.secrets.server.network.enable = true;}
|
|
];
|
|
};
|
|
|
|
systemArgs = modules // args;
|
|
in {
|
|
nixosConfigurations.${name} = mylib.nixosSystem systemArgs;
|
|
|
|
colmena.${name} =
|
|
mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;});
|
|
|
|
# generate proxmox image for virtual machines without desktop environment
|
|
packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox;
|
|
}
|