From 7a11b32af37d03099cdda8ef3bce0da267dab1ba Mon Sep 17 00:00:00 2001 From: Sumner Evans Date: Fri, 20 Sep 2024 06:37:47 -0600 Subject: [PATCH] ipv6: enable Signed-off-by: Sumner Evans --- nixos/hosts/matrix/default.nix | 5 ++++- nixos/hosts/mineshspc/default.nix | 7 +++++-- nixos/hosts/monitoring/default.nix | 5 ++++- nixos/modules/networking.nix | 15 +++++++++++++-- 4 files changed, 26 insertions(+), 6 deletions(-) diff --git a/nixos/hosts/matrix/default.nix b/nixos/hosts/matrix/default.nix index e3b5d55..a043562 100644 --- a/nixos/hosts/matrix/default.nix +++ b/nixos/hosts/matrix/default.nix @@ -47,7 +47,10 @@ networking.hostName = "matrix"; systemd.network.networks = { - "10-wan".matchConfig.MACAddress = "96:00:02:23:cd:a5"; + "10-wan" = { + matchConfig.MACAddress = "96:00:02:23:cd:a5"; + address = [ "2a01:4ff:f0:ec8::1/64" ]; + }; "10-nevarronet".matchConfig.MACAddress = "86:00:00:44:d6:83"; }; diff --git a/nixos/hosts/mineshspc/default.nix b/nixos/hosts/mineshspc/default.nix index 0eacd0a..5ae59fa 100644 --- a/nixos/hosts/mineshspc/default.nix +++ b/nixos/hosts/mineshspc/default.nix @@ -14,8 +14,11 @@ in { networking.hostName = "mineshspc"; systemd.network.networks = { - "10-wan".matchConfig.MACAddress = "96:00:01:f3:c7:74"; - "10-nevarronet".matchConfig.MACAddress = "86:00:00:3a:eb:6a"; + "10-wan" = { + matchConfig.MACAddress = "96:00:01:f3:c7:74"; + address = [ "2a01:4ff:f0:abdd::1/64" ]; + }; + "10-nevarronet" = { matchConfig.MACAddress = "86:00:00:3a:eb:6a"; }; }; services.nginx = { diff --git a/nixos/hosts/monitoring/default.nix b/nixos/hosts/monitoring/default.nix index c1cb6cb..1f165a6 100644 --- a/nixos/hosts/monitoring/default.nix +++ b/nixos/hosts/monitoring/default.nix @@ -6,7 +6,10 @@ in { networking.hostName = "monitoring"; systemd.network.networks = { - "10-wan".matchConfig.MACAddress = "96:00:02:1f:07:ec"; + "10-wan" = { + matchConfig.MACAddress = "96:00:02:1f:07:ec"; + address = [ "2a01:4ff:f0:9b5d::1/64" ]; + }; "10-nevarronet".matchConfig.MACAddress = "86:00:00:43:8c:62"; }; diff --git a/nixos/modules/networking.nix b/nixos/modules/networking.nix index 4aa8069..82446d6 100644 --- a/nixos/modules/networking.nix +++ b/nixos/modules/networking.nix @@ -4,8 +4,19 @@ systemd.network = { enable = true; networks = { - "10-wan".networkConfig.DHCP = "ipv4"; - "10-nevarronet".networkConfig.DHCP = "ipv4"; + "10-wan" = { + networkConfig = { + DHCP = "yes"; + IPv6AcceptRA = true; + }; + routes = [{ routeConfig.Gateway = "fe80::1"; }]; + }; + "10-nevarronet" = { + networkConfig = { + DHCP = "yes"; + IPv6AcceptRA = true; + }; + }; }; };