1

System: Enable IPv6

This commit is contained in:
2025-03-16 15:30:47 +01:00
parent 86f6805662
commit 4d8ac4d1f6
3 changed files with 14 additions and 5 deletions

View File

@ -68,7 +68,7 @@ in {
networking = {
# Gets inherited from flake in nixos mylib and passed through the module option
hostName = cfg.hostname; # Define your hostname.
enableIPv6 = false;
enableIPv6 = true;
# Disable a lot of stuff not needed for systemd-networkd
networkmanager.enable = false;

View File

@ -16,11 +16,18 @@
# This should override the default network 50-ether
"10-ether-2_5G" = mylib.networking.mkStaticSystemdNetwork {
interface = "enp8s0";
ip = ["192.168.86.50/24"];
router = ["192.168.86.5"];
nameserver = ["192.168.86.26"];
ip = ["192.168.86.50/24" "fd00::32/120"];
router = ["192.168.86.5" "fd00::5"];
nameserver = ["192.168.86.26" "fd00::1a"];
routable = true;
};
"10-ether-1G" = mylib.networking.mkStaticSystemdNetwork {
interface = "enp5s0";
ip = ["192.168.86.50/24" "fd00::32/120"];
router = ["192.168.86.5" "fd00::5"];
nameserver = ["192.168.86.26" "fd00::1a"];
routable = false;
};
# "10-ether-1G" = mylib.networking.mkStaticSystemdNetwork {...};
};

View File

@ -54,8 +54,10 @@
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault false; # NOTE: Set to false bc systemd-networkd
networking.enableIPv6 = false;
networking.enableIPv6 = lib.mkDefault false; # NOTE: Could be overwritten by systemd-networkd
# networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true;
# networking.interfaces.enp4s0u2.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;