Clean up networking configs by making them all use the same layout
Also use the v6 gateway as a nameserver as well for the esphome host.
This commit is contained in:
parent
e88982d7c7
commit
b30015fee1
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
|
@ -11,10 +11,9 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
defaultGateway = "10.31.210.1";
|
defaultGateway = "10.31.210.1";
|
||||||
nameservers = [
|
nameservers = [ "10.31.210.1" ];
|
||||||
"10.31.210.1"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "1E:EF:2D:92:81:DA";
|
matchConfig.MACAddress = "1E:EF:2D:92:81:DA";
|
||||||
linkConfig.Name = "net0";
|
linkConfig.Name = "net0";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
|
@ -11,10 +11,9 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
defaultGateway = "10.31.210.1";
|
defaultGateway = "10.31.210.1";
|
||||||
nameservers = [
|
nameservers = [ "10.31.210.1" ];
|
||||||
"10.31.210.1"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "D2:10:33:B1:72:C3";
|
matchConfig.MACAddress = "D2:10:33:B1:72:C3";
|
||||||
linkConfig.Name = "net0";
|
linkConfig.Name = "net0";
|
||||||
|
|
|
@ -1,20 +1,19 @@
|
||||||
# Sources for this configuration:
|
|
||||||
# - https://nixos.wiki/wiki/Networking
|
|
||||||
|
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.159";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.159";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "BC:24:11:37:F0:AB";
|
matchConfig.MACAddress = "BC:24:11:37:F0:AB";
|
||||||
|
|
|
@ -1,27 +1,26 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "10.31.208.24";
|
{
|
||||||
prefixLength = 23;
|
address = "10.31.208.24";
|
||||||
}
|
prefixLength = 23;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
ipv6.addresses = [
|
||||||
|
{
|
||||||
|
address = "2a07:c480:0:1d0::66";
|
||||||
|
prefixLength = 64;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "10.31.208.1";
|
||||||
|
defaultGateway6 = "2a07:c480:0:1d0::1";
|
||||||
|
nameservers = [ "10.31.208.1" "2a07:c480:0:1d0::1" ];
|
||||||
|
search = [ "z9.ccchh.net" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "10.31.208.1";
|
|
||||||
networking.nameservers = [ "10.31.208.1" ];
|
|
||||||
networking.search = [ "z9.ccchh.net" ];
|
|
||||||
|
|
||||||
networking.interfaces.net0 = {
|
|
||||||
ipv6.addresses = [
|
|
||||||
{
|
|
||||||
address = "2a07:c480:0:1d0::66";
|
|
||||||
prefixLength = 64;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
networking.defaultGateway6 = "2a07:c480:0:1d0::1";
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "7E:3C:F0:77:8A:F4";
|
matchConfig.MACAddress = "7E:3C:F0:77:8A:F4";
|
||||||
|
|
|
@ -1,17 +1,19 @@
|
||||||
{ config, pkgs, ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.155";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.155";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "1E:E0:4E:D0:DA:BE";
|
matchConfig.MACAddress = "1E:E0:4E:D0:DA:BE";
|
||||||
|
|
|
@ -4,27 +4,26 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "212.12.51.136";
|
{
|
||||||
prefixLength = 28;
|
address = "212.12.51.136";
|
||||||
}
|
prefixLength = 28;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
ipv6.addresses = [
|
||||||
|
{
|
||||||
|
address = "2a00:14b0:f000:23:51:136::1";
|
||||||
|
prefixLength = 64;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "212.12.51.129";
|
||||||
|
defaultGateway6 = "2a00:14b0:f000:23::1";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "212.12.51.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
networking.interfaces.net0 = {
|
|
||||||
ipv6.addresses = [
|
|
||||||
{
|
|
||||||
address = "2a00:14b0:f000:23:51:136::1";
|
|
||||||
prefixLength = 64;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
networking.defaultGateway6 = "2a00:14b0:f000:23::1";
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "92:7B:E6:12:A4:FA";
|
matchConfig.MACAddress = "92:7B:E6:12:A4:FA";
|
||||||
|
|
|
@ -1,17 +1,19 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.150";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.150";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "2A:A5:80:C3:8E:32";
|
matchConfig.MACAddress = "2A:A5:80:C3:8E:32";
|
||||||
|
|
|
@ -1,17 +1,19 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.161";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.161";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "BC:24:11:C9:F8:C5";
|
matchConfig.MACAddress = "BC:24:11:C9:F8:C5";
|
||||||
|
|
|
@ -1,20 +1,21 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
interfaces.net0 = {
|
interfaces.net0 = {
|
||||||
ipv4.addresses = [ {
|
ipv4.addresses = [
|
||||||
address = "10.31.208.14";
|
{
|
||||||
prefixLength = 23;
|
address = "10.31.208.14";
|
||||||
} ];
|
prefixLength = 23;
|
||||||
};
|
}
|
||||||
defaultGateway = "10.31.208.1";
|
];
|
||||||
nameservers = [
|
|
||||||
"10.31.210.1"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
systemd.network.links."10-net0" = {
|
|
||||||
matchConfig.MACAddress = "BC:24:11:48:85:73";
|
|
||||||
linkConfig.Name = "net0";
|
|
||||||
};
|
};
|
||||||
|
defaultGateway = "10.31.208.1";
|
||||||
|
nameservers = [ "10.31.210.1" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.network.links."10-net0" = {
|
||||||
|
matchConfig.MACAddress = "BC:24:11:48:85:73";
|
||||||
|
linkConfig.Name = "net0";
|
||||||
|
};
|
||||||
}
|
}
|
|
@ -1,23 +1,19 @@
|
||||||
# Networking configuration for the host.
|
{ ... }:
|
||||||
# Sources for this configuration:
|
|
||||||
# - https://nixos.org/manual/nixos/stable/#sec-networking
|
|
||||||
# - https://nixos.wiki/wiki/Systemd-networkd
|
|
||||||
# - https://wiki.archlinux.org/title/Systemd-networkd
|
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.149";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.149";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "62:ED:44:20:7C:C1";
|
matchConfig.MACAddress = "62:ED:44:20:7C:C1";
|
||||||
|
|
|
@ -1,19 +1,19 @@
|
||||||
# Networking configuration for the host.
|
{ ... }:
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.158";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.158";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "BC:24:11:6A:33:5F";
|
matchConfig.MACAddress = "BC:24:11:6A:33:5F";
|
||||||
|
|
|
@ -11,9 +11,7 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
defaultGateway = "10.31.208.1";
|
defaultGateway = "10.31.208.1";
|
||||||
nameservers = [
|
nameservers = [ "10.31.208.1" ];
|
||||||
"10.31.208.1"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
|
|
|
@ -1,17 +1,19 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.151";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.151";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "86:72:08:F6:C0:D6";
|
matchConfig.MACAddress = "86:72:08:F6:C0:D6";
|
||||||
|
|
|
@ -1,20 +1,19 @@
|
||||||
# Sources for this configuration:
|
|
||||||
# - https://nixos.wiki/wiki/Networking
|
|
||||||
|
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.interfaces.net0 = {
|
networking = {
|
||||||
ipv4.addresses = [
|
interfaces.net0 = {
|
||||||
{
|
ipv4.addresses = [
|
||||||
address = "172.31.17.160";
|
{
|
||||||
prefixLength = 25;
|
address = "172.31.17.160";
|
||||||
}
|
prefixLength = 25;
|
||||||
];
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultGateway = "172.31.17.129";
|
||||||
|
nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
||||||
|
search = [ "hamburg.ccc.de" ];
|
||||||
};
|
};
|
||||||
networking.defaultGateway = "172.31.17.129";
|
|
||||||
networking.nameservers = [ "212.12.50.158" "192.76.134.90" ];
|
|
||||||
networking.search = [ "hamburg.ccc.de" ];
|
|
||||||
|
|
||||||
systemd.network.links."10-net0" = {
|
systemd.network.links."10-net0" = {
|
||||||
matchConfig.MACAddress = "BC:24:11:5F:A9:B7";
|
matchConfig.MACAddress = "BC:24:11:5F:A9:B7";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
|
|
Loading…
Reference in a new issue