feat: exclude anycast0 addresses

- exclude managing anycast interfaces on per-node basis
- update all hosts with anycast loopback0 to anycast0
This commit is contained in:
Ben Vincent 2025-05-11 16:13:10 +10:00
parent 19bc2002ee
commit 1726fa3702
12 changed files with 24 additions and 24 deletions

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('profiles::consul::server::anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('profiles::consul::server::anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('profiles::consul::server::anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('profiles::consul::server::anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('profiles::consul::server::anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_master_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_master_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_master_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_resolver_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_resolver_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -11,7 +11,7 @@ networking::interfaces:
type: physical
forwarding: true
dhcp: true
loopback0:
anycast0:
type: dummy
ipaddress: "%{hiera('dns_resolver_anycast_ip')}"
netmask: 255.255.255.255
@ -24,7 +24,7 @@ frrouting::ospfd_redistribute:
frrouting::ospfd_interfaces:
eth0:
area: 0.0.0.0
loopback0:
anycast0:
area: 0.0.0.0
frrouting::daemons:
ospfd: true

View File

@ -46,8 +46,8 @@ class profiles::dns::base (
# export dns records for client
$facts['networking']['interfaces'].each | $interface, $data | {
# exclude those without ipv4 address, and lo
if $data['ip'] and $interface != 'lo' {
# exclude those without ipv4 address, lo and anycast addresses
if $data['ip'] and $interface != 'lo' and $interface !~ /^anycast[0-9]$/ {
# use defaults for the primary_interface
if $interface == $primary_interface {