1
0
Fork 0
nixfiles/hosts/carbon/configuration.nix

51 lines
1.1 KiB
Nix

{ config, pkgs, ... }:
{
imports =
[
./hardware-configuration.nix
../../configuration/common
../../configuration/router
];
boot.kernelParams = [ "console=ttyS0,115200n8" ];
boot.loader.grub.enable = true;
boot.loader.grub.version = 2;
boot.loader.grub.device = "/dev/sda";
boot.loader.grub.extraConfig = "
serial --speed=115200 --unit=0 --word=8 --parity=no --stop=1
terminal_input serial
terminal_output serial
";
networking.hostName = "carbon";
networking.useDHCP = false;
networking.interfaces.enp1s0.useDHCP = true;
networking.wireguard.enable = true;
networking.wireguard.interfaces = {
wg-gatekeeper = {
ips = [
"10.20.30.104/24"
"2a01:4f8:c0c:15f1::8104/113"
];
allowedIPsAsRoutes = false;
peers = [
{
allowedIPs = [
"0.0.0.0/0"
"::/0"
];
endpoint = "gatekeeper.net.clerie.de:51820";
publicKey = "2p1Jqs3bkXbXHFWE6vp1yxHIFoUaZQEARS2nJzbkuBA=";
}
];
privateKeyFile = "/var/src/secrets/wireguard/wg-gatekeeper";
};
};
system.stateVersion = "21.03";
}