system/machines/magenta/networking.nix

34 lines
858 B
Nix
Raw Normal View History

2022-10-13 07:47:31 +03:00
{ lib, ... }:
{
# This file was populated at runtime with the networking
# details gathered from the active system.
networking = {
nameservers = [
"188.93.16.19"
"188.93.17.19"
"8.8.8.8"
];
defaultGateway = "45.131.41.1";
defaultGateway6 = "";
dhcpcd.enable = false;
usePredictableInterfaceNames = lib.mkForce false;
interfaces = {
eth0 = {
ipv4.addresses = [
{ address = "45.131.41.215"; prefixLength = 24; }
];
ipv6.addresses = [
{ address = "fe80::f816:3eff:fe58:d30a"; prefixLength = 64; }
];
ipv4.routes = [{ address = "45.131.41.1"; prefixLength = 32; }];
ipv6.routes = [{ address = ""; prefixLength = 128; }];
};
};
};
services.udev.extraRules = ''
ATTR{address}=="fa:16:3e:58:d3:0a", NAME="eth0"
'';
}