1
0
Fork 0
mirror of https://github.com/mdlayher/homelab.git synced 2024-12-14 11:47:32 +00:00

nixos/lib/vargen: add 10GbE switch

This commit is contained in:
Matt Layher 2020-05-25 20:14:53 -04:00
parent 3089041870
commit a9368c0787
2 changed files with 19 additions and 2 deletions

View file

@ -31,7 +31,8 @@ func main() {
},
}
lan0 = newSubnet("lan0", 10)
lan0 = newSubnet("lan0", 10)
tengb0 = newSubnet("tengb0", 100)
)
// Set up the output structure and create host/infra records.
@ -70,6 +71,12 @@ func main() {
ip("192.168.1.3"),
mac("f0:9f:c2:ce:7e:e1"),
),
newHost(
"switch-office02",
tengb0,
ip("192.168.100.2"),
mac("c4:ad:34:ba:40:82"),
),
newHost(
"ap-livingroom02",
enp2s0,
@ -86,7 +93,7 @@ func main() {
out.addInterface("guest0", newSubnet("guest0", 9))
out.addInterface("iot0", newSubnet("iot0", 66))
out.addInterface("lab0", newSubnet("lab0", 2))
out.addInterface("tengb0", newSubnet("tengb0", 100))
out.addInterface("tengb0", tengb0)
out.addInterface("wg0", newSubnet("wg0", 20))
// TODO: wan0 is a special case but should probably live in its own

View file

@ -53,6 +53,16 @@
},
"mac": "f0:9f:c2:ce:7e:e1"
},
{
"name": "switch-office02",
"ipv4": "192.168.100.2",
"ipv6": {
"gua": "2600:6c4a:7880:3264:c6ad:34ff:feba:4082",
"ula": "fd9e:1a04:f01d:100:c6ad:34ff:feba:4082",
"lla": "fe80::c6ad:34ff:feba:4082"
},
"mac": "c4:ad:34:ba:40:82"
},
{
"name": "ap-livingroom02",
"ipv4": "192.168.1.5",