infra/nix/monitoring/networking.nix
Gabriel Simmer 9439acf4d1
All checks were successful
Lint / lint (push) Successful in 18s
Build Pi NixOS Image / sync (push) Successful in 26m51s
format with alejandra style
2024-02-05 13:13:44 +00:00

53 lines
1.1 KiB
Nix

{lib, ...}: {
# This file was populated at runtime with the networking
# details gathered from the active system.
networking = {
nameservers = [
"8.8.8.8"
];
defaultGateway = "172.31.1.1";
defaultGateway6 = {
address = "fe80::1";
interface = "eth0";
};
dhcpcd.enable = false;
usePredictableInterfaceNames = lib.mkForce false;
interfaces = {
eth0 = {
ipv4.addresses = [
{
address = "91.107.206.145";
prefixLength = 32;
}
];
ipv6.addresses = [
{
address = "2a01:4f8:c012:5ec6::1";
prefixLength = 64;
}
{
address = "fe80::9400:2ff:fe83:3979";
prefixLength = 64;
}
];
ipv4.routes = [
{
address = "172.31.1.1";
prefixLength = 32;
}
];
ipv6.routes = [
{
address = "fe80::1";
prefixLength = 128;
}
];
};
};
};
services.udev.extraRules = ''
ATTR{address}=="96:00:02:83:39:79", NAME="eth0"
'';
}