chore: add static IPs for the routers+fix dhcp

This commit is contained in:
surtur 2021-05-20 06:13:09 +02:00
parent d80ece7146
commit 0293202096
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D
2 changed files with 38 additions and 5 deletions

@ -78,3 +78,36 @@ packages:
package_upgrade: true
package_reboot_if_required: true
network:
version: 2
ethernets:
eth2_r_eedge:
match:
macaddress: '00:07:00:13:37:24'
dhcp4: false
addresses:
- 10.16.7.1/24
gateway4: 10.16.6.1
nameservers:
addresses: [8.8.8.8]
routes:
- to: 10.16.5.0/24
via: 10.16.6.1
metric: 3
eth2_r_upstream:
match:
macaddress: '00:07:00:13:37:25'
dhcp4: false
addresses:
- 10.16.6.2/24
gateway4: 10.16.6.1
nameservers:
addresses: [8.8.8.8]
routes:
- to: 10.16.5.0/24
via: 10.16.7.1
metric: 3

@ -16,7 +16,7 @@ networkname = "default" # default==NAT
subnets = ["10.16.4.0/24", "10.16.5.0/24", "10.16.6.0/24", "10.16.7.0/30"]
network_names = ["inner", "outer", "dmz", "router"]
dhcp = [true, false, false, false]
dhcp = [true, true, false, false]
# host-specific settings
# RAM in bytes
@ -53,8 +53,8 @@ hosts = {
network = {
"outer" = {
name = "outer",
mode = "route",
address = ["10.16.5.1"],
mode = "dhcp",
address = ["10.16.5.4"],
mac = "00:05:00:13:37:23",
},
}
@ -97,8 +97,8 @@ hosts = {
network = {
"outer" = {
name = "outer",
mode = "route",
address = ["10.16.5.1"],
mode = "dhcp",
address = ["10.16.5.3"],
mac = "00:05:00:13:37:25",
},
"router" = {