From b702dfc362d16e11d96debc39a2dcdcc72619277 Mon Sep 17 00:00:00 2001 From: Christian Breunig Date: Thu, 13 Feb 2025 17:03:35 +0100 Subject: bgp: T7161: fix IPv4/IPv6 unicast AFI "redistribute table" command Re-use existing XML constraint added via commit 8f6246da6 ("xml: T7161: provide re-usable building block for alternative routing tables") and add handy CLI completion helper. FRRouting supports redistribution of multiple non-main tables, thus make this a multi node in addition, too. --- data/templates/frr/bgpd.frr.j2 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'data/templates/frr/bgpd.frr.j2') diff --git a/data/templates/frr/bgpd.frr.j2 b/data/templates/frr/bgpd.frr.j2 index 51a3f2564..2f3719fdf 100644 --- a/data/templates/frr/bgpd.frr.j2 +++ b/data/templates/frr/bgpd.frr.j2 @@ -310,7 +310,9 @@ router bgp {{ system_as }} {{ 'vrf ' ~ vrf if vrf is vyos_defined }} {% if afi_config.redistribute is vyos_defined %} {% for protocol, protocol_config in afi_config.redistribute.items() %} {% if protocol == 'table' %} - redistribute table {{ protocol_config.table }} +{% for table in protocol_config %} + redistribute table-direct {{ table }} +{% endfor %} {% else %} {% set redistribution_protocol = protocol %} {% if protocol == 'ospfv3' %} -- cgit v1.2.3