Skip to content

Build bgp.advertise lists to simplify configuration templates#3234

Merged
ipspace merged 3 commits intodevfrom
bgp-advertise
Mar 23, 2026
Merged

Build bgp.advertise lists to simplify configuration templates#3234
ipspace merged 3 commits intodevfrom
bgp-advertise

Conversation

@ipspace
Copy link
Copy Markdown
Owner

@ipspace ipspace commented Mar 23, 2026

This commit builds node- and VRF-level bgp.advertise lists that contain IPv4/IPv6 prefixes that have to be advertised as BGP prefixes. The list is built from interface data (using bgp.advertise attribute) and the bgp.originate node-level list.

FRR implementation is included as a proof-of-concept.

This commit builds node- and VRF-level bgp.advertise lists that contain
IPv4/IPv6 prefixes that have to be advertised as BGP prefixes. The list
is built from interface data (using bgp.advertise attribute) and the
bgp.originate node-level list.

FRR implementation is included as a proof-of-concept.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a derived bgp.advertise list at node- and VRF-level to centralize “what prefixes should be originated into BGP” and updates FRR templates/docs to consume that list instead of re-deriving prefixes from interface/originate data.

Changes:

  • Build bgp.advertise lists from interface bgp.advertise flags and bgp.originate.
  • Update FRR BGP templates (global + VRF) to generate network statements from bgp.advertise.
  • Refresh multiple topology expected outputs and developer docs to reflect the new data model.

Reviewed changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
tests/topology/expected/vrf.yml Expected VRF node data now includes vrfs.*.bgp.advertise lists
tests/topology/expected/vrf-routing-blocks.yml Expected VRF routing-block outputs updated with bgp.advertise
tests/topology/expected/vrf-links.yml Expected VRF link scenarios updated with bgp.advertise
tests/topology/expected/vrf-igp.yml Expected VRF+IGP outputs updated with bgp.advertise
tests/topology/expected/mpls-vpn-simple.yml Expected MPLS/VPN outputs updated with bgp.advertise
tests/topology/expected/fabric-ebgp.yml Expected fabric EBGP outputs updated with bgp.advertise
tests/topology/expected/evpn-vlan-attr.yml Expected EVPN VLAN attribute outputs updated with bgp.advertise
tests/topology/expected/evpn-node-vrf.yml Expected EVPN node VRF outputs updated with bgp.advertise
tests/topology/expected/evpn-l3vni-only.yml Expected EVPN L3VNI-only outputs updated with bgp.advertise
tests/topology/expected/evpn-asymmetric-irb-ospf.yml Expected EVPN asymmetric IRB outputs updated with bgp.advertise
tests/topology/expected/components.yml Expected component test outputs updated with bgp.advertise
tests/topology/expected/bgp.yml Expected base BGP outputs updated with node bgp.advertise
tests/topology/expected/bgp-ibgp-localas.yml Expected iBGP local-as outputs updated with node bgp.advertise
tests/topology/expected/bgp-af-rt-929.yml Expected AF regression outputs updated with node bgp.advertise
netsim/modules/bgp.py Adds bgp_build_advertise_list and wires it into BGP post-transform
netsim/ansible/templates/vrf/frr.bgp.j2 Switches VRF network statements to use vdata.bgp.advertise
netsim/ansible/templates/bgp/frr.j2 Switches global network statements to use bgp.advertise
docs/dev/config/bgp.md Updates template author guidance to use the new bgp.advertise lists

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 42 out of 49 changed files in this pull request and generated 1 comment.

ipspace added a commit that referenced this pull request Mar 23, 2026
@ipspace ipspace merged commit 3b590df into dev Mar 23, 2026
6 checks passed
@ipspace ipspace deleted the bgp-advertise branch March 23, 2026 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants