From 2147b568644d3daf894bb9e33ed70faab388da2e Mon Sep 17 00:00:00 2001 From: Felix Albrigtsen Date: Sat, 28 Sep 2024 21:28:26 +0200 Subject: [PATCH] Add ipv6 gateway --- base/networking.nix | 9 +++------ values.nix | 4 +++- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/base/networking.nix b/base/networking.nix index 1272b1e..5c710a3 100644 --- a/base/networking.nix +++ b/base/networking.nix @@ -1,16 +1,13 @@ { lib, values, ... }: { + systemd.network.enable = true; networking.domain = "pvv.ntnu.no"; networking.useDHCP = false; - # networking.search = [ "pvv.ntnu.no" "pvv.org" ]; - # networking.nameservers = lib.mkDefault [ "129.241.0.200" "129.241.0.201" ]; - # networking.tempAddresses = lib.mkDefault "disabled"; - # networking.defaultGateway = values.hosts.gateway; - systemd.network.enable = true; + # The rest of the networking configuration is usually sourced from /values.nix services.resolved = { enable = lib.mkDefault true; dnssec = "false"; # Supposdly this keeps breaking and the default is to allow downgrades anyways... }; -} \ No newline at end of file +} diff --git a/values.nix b/values.nix index a623f37..2e9d266 100644 --- a/values.nix +++ b/values.nix @@ -25,6 +25,8 @@ in rec { hosts = { gateway = pvv-ipv4 129; + gateway6 = pvv-ipv6 1; + bekkalokk = { ipv4 = pvv-ipv4 168; ipv6 = pvv-ipv6 168; @@ -63,7 +65,7 @@ in rec { defaultNetworkConfig = { dns = [ "129.241.0.200" "129.241.0.201" "2001:700:300:1900::200" "2001:700:300:1900::201" ]; domains = [ "pvv.ntnu.no" "pvv.org" ]; - gateway = [ hosts.gateway ]; + gateway = [ hosts.gateway hosts.gateway6 ]; networkConfig.IPv6AcceptRA = "no"; DHCP = "no"; -- 2.44.2