97 lines
3.1 KiB
Plaintext
97 lines
3.1 KiB
Plaintext
|
frr defaults datacenter
|
||
|
hostname {{ansible_hostname}}
|
||
|
!
|
||
|
service integrated-vtysh-config
|
||
|
!
|
||
|
log syslog informational
|
||
|
!
|
||
|
{% if autobgp_interfaces is defined and autobgp_interfaces != [] %}
|
||
|
{% for item in autobgp_interfaces %}
|
||
|
interface {{ item['name'] }}
|
||
|
ipv6 nd ra-interval 10
|
||
|
no ipv6 nd suppress-ra
|
||
|
!
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
|
||
|
|
||
|
router bgp {{host_ASN}}
|
||
|
bgp router-id {{host_loopback_IP}}
|
||
|
bgp bestpath as-path multipath-relax
|
||
|
bgp bestpath compare-routerid
|
||
|
{% if autobgp_interfaces is defined and autobgp_interfaces != [] %}
|
||
|
neighbor fabric peer-group
|
||
|
neighbor fabric remote-as external
|
||
|
neighbor fabric description Internal Fabric Network
|
||
|
neighbor fabric capability extended-nexthop
|
||
|
{% endif %}
|
||
|
{% if addressed_interfaces is defined and addressed_interfaces != [] %}
|
||
|
{% for item in addressed_interfaces %}
|
||
|
{% if item['bgpPeerIP'] is defined %}
|
||
|
neighbor {{ item['bgpPeerIP'] }} remote-as {{ item['bgpPeerASN'] }}
|
||
|
{% endif %}
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
{% if autobgp_interfaces is defined and autobgp_interfaces != [] %}
|
||
|
{% for item in autobgp_interfaces %}
|
||
|
neighbor {{ item['name'] }} interface peer-group fabric
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
{% if frr_other_peers is defined and frr_other_peers != [] %}
|
||
|
{% for item in frr_other_peers %}
|
||
|
neighbor {{ item['ip'] }} remote-as {{ item['remote_ASN'] }}
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
!
|
||
|
address-family ipv4 unicast
|
||
|
network {{host_loopback_IP}}/32
|
||
|
{% if autobgp_interfaces is defined and autobgp_interfaces != [] %}
|
||
|
neighbor fabric activate
|
||
|
neighbor fabric prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endif %}
|
||
|
{% if frr_other_peers is defined and frr_other_peers != [] %}
|
||
|
{% for item in frr_other_peers %}
|
||
|
neighbor {{ item['ip'] }} remote-as {{ item['remote_ASN'] }} prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
{% if addressed_interfaces is defined and addressed_interfaces != [] %}
|
||
|
{% for item in addressed_interfaces %}
|
||
|
{% if item['bgpPeerIP'] is defined %}
|
||
|
neighbor {{ item['bgpPeerIP'] }} prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endif %}
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
exit-address-family
|
||
|
!
|
||
|
address-family ipv6 unicast
|
||
|
network {{host_loopback_IP_v6}}/128
|
||
|
{% if frr_other_peers is defined and frr_other_peers != [] %}
|
||
|
{% for item in frr_other_peers %}
|
||
|
neighbor {{ item['ip'] }} prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
{% if autobgp_interfaces is defined and autobgp_interfaces != [] %}
|
||
|
neighbor fabric activate
|
||
|
neighbor fabric prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endif %}
|
||
|
{% if addressed_interfaces is defined and addressed_interfaces != [] %}
|
||
|
{% for item in addressed_interfaces %}
|
||
|
{% if item['bgpPeerIP'] is defined %}
|
||
|
neighbor {{ item['bgpPeerIP'] }} prefix-list AS{{host_ASN}}-OUT out
|
||
|
{% endif %}
|
||
|
{% endfor %}
|
||
|
{% endif %}
|
||
|
exit-address-family
|
||
|
!
|
||
|
address-family l2vpn evpn
|
||
|
neighbor fabric activate
|
||
|
advertise-all-vni
|
||
|
advertise-default-gw
|
||
|
exit-address-family
|
||
|
!
|
||
|
ip prefix-list AS{{host_ASN}}-OUT seq 5 permit {{host_loopback_IP}}/32
|
||
|
!
|
||
|
ipv6 prefix-list AS{{host_ASN}}-OUT seq 5 permit {{host_loopback_IP_v6}}/128
|
||
|
line vty
|
||
|
!
|