Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bgp template changes for new multi Asic minigraph #4488

Merged
merged 3 commits into from
May 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions dockers/docker-fpm-frr/frr/bgpd/bgpd.main.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ipv6 prefix-list PL_LoopbackV6 permit {{ get_ipv6_loopback_address(LOOPBACK_INTE
{% endif %}
!
!
{% if DEVICE_METADATA['localhost']['type'] == 'InternalFrontend' %}
{% if DEVICE_METADATA['localhost']['sub_role'] == 'FrontEnd' %}
route-map HIDE_INTERNAL permit 10
set community local-AS
!
Expand Down Expand Up @@ -62,7 +62,7 @@ router bgp {{ DEVICE_METADATA['localhost']['bgp_asn'] }}
{% endblock vlan_advertisement %}
!
!
{% if DEVICE_METADATA['localhost']['type'] == 'InternalFrontend' %}
{% if DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
redistribute connected route-map HIDE_INTERNAL
{% endif %}
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@
{% if neighbor_addr | ipv4 %}
address-family ipv4
neighbor {{ neighbor_addr }} peer-group PEER_V4
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'InternalBackend' %}
{% if CONFIG_DB__DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
neighbor {{ neighbor_addr }} route-map FROM_BGP_PEER_V4_INT in
{% endif %}
{% elif neighbor_addr | ipv6 %}
address-family ipv6
neighbor {{ neighbor_addr }} peer-group PEER_V6
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'InternalBackend' %}
{% if CONFIG_DB__DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
neighbor {{ neighbor_addr }} route-map FROM_BGP_PEER_V6_INT in
{% endif %}
{% endif %}
Expand All @@ -34,6 +34,9 @@
{% if bgp_session['nhopself'] | int != 0 %}
neighbor {{ neighbor_addr }} next-hop-self
{% endif %}
{% if 'ASIC' in bgp_session['name'] %}
neighbor {{ neighbor_addr }} next-hop-self force
{% endif %}
!
{% if bgp_session["asn"] == bgp_asn and CONFIG_DB__DEVICE_METADATA['localhost']['type'] == "SpineChassisFrontendRouter" %}
address-family l2vpn evpn
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
address-family ipv4
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'ToRRouter' %}
neighbor PEER_V4 allowas-in 1
{% endif %}
{% if CONFIG_DB__DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
neighbor PEER_V4 route-reflector-client
{% endif %}
neighbor PEER_V4 soft-reconfiguration inbound
neighbor PEER_V4 route-map FROM_BGP_PEER_V4 in
Expand All @@ -14,6 +17,9 @@
address-family ipv6
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'ToRRouter' %}
neighbor PEER_V6 allowas-in 1
{% endif %}
{% if CONFIG_DB__DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
neighbor PEER_V6 route-reflector-client
{% endif %}
neighbor PEER_V6 soft-reconfiguration inbound
neighbor PEER_V6 route-map FROM_BGP_PEER_V6 in
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ route-map FROM_BGP_PEER_V6 permit 100
!
route-map TO_BGP_PEER_V6 permit 100
!
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'InternalBackend' %}
{% if CONFIG_DB__DEVICE_METADATA['localhost']['sub_role'] == 'BackEnd' %}
route-map FROM_BGP_PEER_V4_INT permit 2
set originator-id {{ loopback0_ipv4 | ip }}
!
Expand Down