44 lines
1.1 KiB
Nix
44 lines
1.1 KiB
Nix
{
|
|
flake,
|
|
config,
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}: {
|
|
networking.hostName = "droppie";
|
|
networking.interfaces.enp2s0f0.useDHCP = true;
|
|
networking.interfaces.enp2s0f1.useDHCP = true;
|
|
|
|
networking.interfaces.enp2s0f0 = {
|
|
ipv6.addresses = [ { address = "2a02:908:5b1:e3c0:3::"; prefixLength = 64; } ];
|
|
};
|
|
|
|
# Allow pub.solar restic backups
|
|
services.openssh.allowSFTP = true;
|
|
services.openssh.openFirewall = true;
|
|
|
|
age.secrets.wg-private-key.file = "${flake.self}/secrets/wg-private-droppie.age";
|
|
|
|
pub-solar.wireguard.private = {
|
|
ownIPs = [
|
|
"10.13.12.3/32"
|
|
"fd00:b12f:acab:1312:acab:3::/96"
|
|
];
|
|
privateKeyFile = config.age.secrets.wg-private-key.path;
|
|
};
|
|
|
|
age.secrets.wg-tunnel-key.file = "${flake.self}/secrets/wg-tunnel-droppie.age";
|
|
|
|
pub-solar.wireguard.tunnel = {
|
|
ownIPs = [
|
|
"10.69.139.214/32"
|
|
"fc00:bbbb:bbbb:bb01::6:8bd5/128"
|
|
];
|
|
privateKeyFile = config.age.secrets.wg-tunnel-key.path;
|
|
peer = {
|
|
publicKey = "m9w2Fr0rcN6R1a9HYrGnUTU176rTZIq2pcsovPd9sms=";
|
|
endpoint = "[2a02:6ea0:d406:1::a18f]:3019";
|
|
};
|
|
};
|
|
}
|