mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-01-31 04:58:01 +00:00
hosts/plover: simplify networking setup
It is simple anyways requiring only one of the ethernet interfaces to be present to the global network while the rest can be in the local network.
This commit is contained in:
parent
ceb821f2c0
commit
9b03f4d4aa
@ -51,26 +51,8 @@ in
|
||||
systemd.network = {
|
||||
enable = true;
|
||||
networks."20-wan" = {
|
||||
matchConfig.Name = "ens3";
|
||||
|
||||
address = [
|
||||
# Public IPs.
|
||||
publicIP
|
||||
"${publicIPv6}1/64"
|
||||
|
||||
# The private network IP.
|
||||
"172.23.0.0/16"
|
||||
|
||||
# Randomly generate from the IPv6 range.
|
||||
"::"
|
||||
];
|
||||
|
||||
routes = [
|
||||
# Configuring the route with the gateway addresses for this network.
|
||||
{ routeConfig.Gateway = "fe80::1"; }
|
||||
{ routeConfig.Destination = privateNetworkGatewayIP; }
|
||||
{ routeConfig = { Gateway = privateNetworkGatewayIP; GatewayOnLink = true; }; }
|
||||
];
|
||||
matchConfig.Name = "en*";
|
||||
networkConfig.DHCP = "yes";
|
||||
};
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user