infrastructure/machines/core-services-01/network.nix
2023-02-24 10:56:54 +01:00

43 lines
752 B
Nix

{ config, ... }:
let
inherit (config) my;
in
{
networking.useNetworkd = true;
systemd.network.networks = {
"10-ens18" = {
name = "ens18";
address = my.ipv4Full;
DHCP = "ipv4";
};
"10-ens19" = {
name = "ens19";
address = with my.ipv6; standardFull ++ [ acmeFull ];
networkConfig.IPv6AcceptRA = true;
ipv6AcceptRAConfig = {
UseOnLinkPrefix = false;
UseAutonomousPrefix = false;
};
};
"10-ens20" = {
name = "ens20";
address = my.ipv4InternalFull;
DHCP = "ipv4";
dhcpV4Config.RouteMetric = 2048;
routes = [
{
routeConfig = {
Destination = "10.0.0.0/8";
};
}
];
};
};
}