Skip to content

Commit

Permalink
[zebra.conf] Avoid zebra crash upon empty configuration (#2203)
Browse files Browse the repository at this point in the history
  • Loading branch information
taoyl-ms authored and lguohan committed Oct 29, 2018
1 parent 1ab2301 commit 6a37365
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions dockers/docker-fpm-quagga/zebra.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,11 @@ ip route 0.0.0.0/0 {{ MGMT_INTERFACE[(name, prefix)]['gwaddr'] }} 200
{% endfor %}
{% endif %}
! Set ip source to loopback for bgp learned routes
{% if lo_ipv4_addrs|length > 0 -%}
route-map RM_SET_SRC permit 10
set src {{ lo_ipv4_addrs[0] | ip }}
!
{% endif %}
{% if lo_ipv6_addrs|length > 0 %}
route-map RM_SET_SRC6 permit 10
set src {{ lo_ipv6_addrs[0] | ip }}
Expand Down

0 comments on commit 6a37365

Please sign in to comment.