6088bd59de
* Initial commit for BGP internal neighbor table support. > Add new template named "internal" for the internal BGP sessions > Add a new table in database "BGP_INTERNAL_NEIGHBOR" > The internal BGP sessions will be stored in this new table "BGP_INTERNAL_NEIGHBOR" * Changes in template generation tests with the introduction of internal neighbor template files.
33 lines
1.1 KiB
Django/Jinja
33 lines
1.1 KiB
Django/Jinja
!
|
|
! template: bgpd/templates/general/peer-group.conf.j2
|
|
!
|
|
neighbor PEER_V4 peer-group
|
|
neighbor PEER_V6 peer-group
|
|
address-family ipv4
|
|
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'ToRRouter' %}
|
|
neighbor PEER_V4 allowas-in 1
|
|
{% elif CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'LeafRouter' %}
|
|
{% if CONFIG_DB__BGP_BBR['status'] == 'enabled' %}
|
|
neighbor PEER_V4 allowas-in 1
|
|
{% endif %}
|
|
{% endif %}
|
|
neighbor PEER_V4 soft-reconfiguration inbound
|
|
neighbor PEER_V4 route-map FROM_BGP_PEER_V4 in
|
|
neighbor PEER_V4 route-map TO_BGP_PEER_V4 out
|
|
exit-address-family
|
|
address-family ipv6
|
|
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'ToRRouter' %}
|
|
neighbor PEER_V6 allowas-in 1
|
|
{% elif CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'LeafRouter' %}
|
|
{% if CONFIG_DB__BGP_BBR['status'] == 'enabled' %}
|
|
neighbor PEER_V6 allowas-in 1
|
|
{% endif %}
|
|
{% endif %}
|
|
neighbor PEER_V6 soft-reconfiguration inbound
|
|
neighbor PEER_V6 route-map FROM_BGP_PEER_V6 in
|
|
neighbor PEER_V6 route-map TO_BGP_PEER_V6 out
|
|
exit-address-family
|
|
!
|
|
! end of template: bgpd/templates/general/peer-group.conf.j2
|
|
!
|