improve network config

This commit is contained in:
Christoph Cullmann 2023-10-24 21:47:13 +02:00
parent d26a580ec8
commit 6d6f1ee2e8
3 changed files with 30 additions and 28 deletions

View file

@ -14,12 +14,21 @@
/data/nixos/common.nix
];
# host name
networking.hostName = "mini";
# main network interface
systemd.network.networks."10-wan".matchConfig.Name = "eno1";
# amd graphics
hardware.opengl.extraPackages = with pkgs; [ amdvlk rocm-opencl-icd rocm-opencl-runtime ];
# use systemd-networkd, fixed IPv4, dynamic IPv6
networking.hostName = "mini";
networking.useDHCP = false;
networking.nameservers = [ "192.168.13.1" ];
systemd.network = {
enable = true;
networks."10-wan" = {
matchConfig.Name = "eno1";
address = [ "192.168.13.100/24" ];
routes = [ { routeConfig.Gateway = "192.168.13.1"; } ];
networkConfig.IPv6AcceptRA = true;
linkConfig.RequiredForOnline = "routable";
};
};
}