2024-07-07 00:24:27 +05:30
|
|
|
{ config, ... }: {
|
|
|
|
imports = [
|
|
|
|
../shared/network.nix
|
|
|
|
../shared/networkd.nix
|
|
|
|
../shared/wireguard.nix
|
|
|
|
];
|
2024-06-29 17:52:32 +05:30
|
|
|
|
2024-07-07 00:24:27 +05:30
|
|
|
sops.secrets = {
|
|
|
|
"wireguard/rico0/pk" = {
|
|
|
|
mode = "400";
|
|
|
|
owner = config.users.users.root.name;
|
|
|
|
group = config.users.users.root.group;
|
|
|
|
};
|
|
|
|
"wireguard/rico0/psk" = {
|
|
|
|
mode = "400";
|
|
|
|
owner = config.users.users.root.name;
|
|
|
|
group = config.users.users.root.group;
|
2024-06-29 17:52:32 +05:30
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-07-07 00:24:27 +05:30
|
|
|
nodeconfig.wireguard = {
|
2024-06-29 17:52:32 +05:30
|
|
|
enable = true;
|
2024-07-07 00:24:27 +05:30
|
|
|
listen-port = 51830;
|
|
|
|
pk-file = config.sops.secrets."wireguard/rico0/pk".path;
|
|
|
|
psk-file = config.sops.secrets."wireguard/rico0/psk".path;
|
|
|
|
node-ips = [
|
|
|
|
"10.10.10.10/24"
|
|
|
|
"fd7c:585c:c4ae::10/64"
|
|
|
|
];
|
2024-06-29 17:52:32 +05:30
|
|
|
};
|
|
|
|
}
|