Skip to content

Commit 227b251

Browse files
mikewiebeskaszlikmtarkingjuburnetmkilar123
authored
[WIP] VXLAN EBGP Support (#497)
* Vxlan ebgp day0. First PR (#489) * move initial ebgp fabric work to new branch * remove tmp file * Update ebgp_vxlan_fabric_base.j2 * swap fabric global name from standup meeting discussion * update defaults key * adjustments from testing with module updates * update after testing module * add backwards compatability for 3.1.1 * fix security support * update security * backout tasks * Fabric type "eBGP_VXLAN" added. * Repo Sync * Fix for issue with Same-Tier-AS option * Removing the rule files * Update ebgp_vxlan_fabric_evpn.j2 To get alligngth with develop branch * Update nac_dc_validate.py * Update nac_dc_validate.py * Update data_model_keys.py * Update data_model_keys.py * Update main.yml * Rename sub_main_bgp.yml to sub_main_ebgp_vxlan.yml * Update main.yml * Rename sub_main_bgp.yml to sub_main_ebgp_vxlan.yml * Update main.yml * Delete roles/dtc/common/tasks/sub_main_bgp.yml * Update defaults.yml * day0 fix - to be able to create a fabric * Var in upercase, changed to lowercase --------- Co-authored-by: Matt Tarkington <mtarking@cisco.com> * Fix for "Multi-AS" option. (#493) * test * test removed * spine_bgp_asn is actually "nvPairs.BGP_AS" so we can reuse existing vxlan.global.bgp_asn * Fix for "Multi-AS" option. The SUPER_SPINE_BGP_AS and BGP_AS_MODE where under wrong IF statement * Updating 'ebgp_vxlan_support' branch to be in sync with 'develop' (#502) Updating ebgp_vxlan_support branch * Fix support boundary for security to be 12.2.2 or higher (#474) * fix support boundary for security to be 12.2.2 or higher * update in base * update in base * Update msd_fabric_general.j2 (#498) * Update msd_fabric_general.j2 * Update msd_fabric_resources.j2 * update defaults for breakout interface and nxapi and bootstrap defaults and isn fabric jinja template (#496) * update defaults for breakout and nxapi * updates multisite isn bootstrap and nxapi defaults --------- Co-authored-by: Matt Tarkington <mtarking@cisco.com> Co-authored-by: juburnet <145139118+juburnet@users.noreply.github.com> * adding missing fabric attributes (#500) * adding missing fabric attributes * added switch removals an additions into the ebgp_vxlan fabrics * adding l3vni without vlan * Sync with netascode/ebgp_vxlan_support branch. 0 files changed (#510) Hi team, I need to clean up my environment, and for that, I've created the PR. However, there are NO CHANGES IN FILES, so the PR WON'T CHANGE ANYTHING. Thanks :) * revert changes back to what is in develop * Adding possibility to configure policies under ebgp fabric (#506) * adding missing fabric attributes * added switch removals an additions into the ebgp_vxlan fabrics * enabling policy configurations in the ebgp fabric * correcting vars * Update sub_main_ebgp_vxlan.yml The file has been updated with PR #507 * fabric.yml * Update sub_main_ebgp_vxlan.yml * replacing symlink with copy of validation file 501 --------- Co-authored-by: Sławomir Kaszlikowski <skaszlik@cisco.com> * VPC for eBPG fabirc (#507) * test * test removed * spine_bgp_asn is actually "nvPairs.BGP_AS" so we can reuse existing vxlan.global.bgp_asn * Fix for "Multi-AS" option. The SUPER_SPINE_BGP_AS and BGP_AS_MODE where under wrong IF statement * work in progress * Switches are adding but playbook is failing on cisco.nac_dc_vxlan.create : Build Switch Hostname Policy Payload from Data Model Update * Fix for "Adding switches ". The process now works as expected * VPC support for eBGP fabric type * Update devices_discovery.yml to the master * Update devices_discovery.yml Bringing back the changes I made * Update sub_main_ebgp_vxlan.yml Update based on Matt suggestion * Update sub_main_ebgp_vxlan.yml Based on Matt conversation * Update sub_main_ebgp_vxlan.yml * Update sub_main_ebgp_vxlan.yml * Update devices_discovery.yml Sync with PR #506 * Update sub_main_ebgp_vxlan.yml Move "Remove Fabric vPC Peering" task above "Remove Fabric Switches" * Update sub_main_ebgp_vxlan.yml Moving "Remove Fabric Switches" to the last task * Update sub_main_ebgp_vxlan.yml * Add missing condition check for VPC "Import Role Tasks" (#516) * test * test removed * spine_bgp_asn is actually "nvPairs.BGP_AS" so we can reuse existing vxlan.global.bgp_asn * Fix for "Multi-AS" option. The SUPER_SPINE_BGP_AS and BGP_AS_MODE where under wrong IF statement * work in progress * Switches are adding but playbook is failing on cisco.nac_dc_vxlan.create : Build Switch Hostname Policy Payload from Data Model Update * Fix for "Adding switches ". The process now works as expected * VPC support for eBGP fabric type * Update devices_discovery.yml to the master * Update devices_discovery.yml Bringing back the changes I made * Update sub_main_ebgp_vxlan.yml Update based on Matt suggestion * Update sub_main_ebgp_vxlan.yml Based on Matt conversation * Update sub_main_ebgp_vxlan.yml * Update sub_main_ebgp_vxlan.yml * Update devices_discovery.yml Sync with PR #506 * Update sub_main_ebgp_vxlan.yml Move "Remove Fabric vPC Peering" task above "Remove Fabric Switches" * Update sub_main_ebgp_vxlan.yml Moving "Remove Fabric Switches" to the last task * Update sub_main_ebgp_vxlan.yml * Missing condition check * Ebgp vxlan support interfaces v1 (#515) * adding missing fabric attributes * added switch removals an additions into the ebgp_vxlan fabrics * adding l3vni without vlan * adding interface config support to ebgp fabric * adding vpc interfaces after vpc support was merged * introducing changes requested by the reviewer * changes requested by reviewer * EBGP fabric :: enabling hourly_backup (#526) * adding missing fabric attributes * added switch removals an additions into the ebgp_vxlan fabrics * adding l3vni without vlan * adding interface config support to ebgp fabric * ebgp fabric creation in ND4.1 + hourly backup * removing unnecessary comment * removing unnecessary comment * removing ND4.1 condition for ALLOW_L3VNI_WO_VLAN * VRF support for eBGP (#517) * test * test removed * spine_bgp_asn is actually "nvPairs.BGP_AS" so we can reuse existing vxlan.global.bgp_asn * Fix for "Multi-AS" option. The SUPER_SPINE_BGP_AS and BGP_AS_MODE where under wrong IF statement * [WIP] VRF enabled but no config on NDFC. * VRF Support * Use common files for managing VRFs for both eBGP and iBGP fabrics * Add 'common_vxlan' only for 'VXLAN_EVPN' and 'eBGP_VXLAN' type of fabric * clean up task name * remove white space * Update vrfs_networks.yml Update vars_common_local in line 88 * J2 if check --------- Co-authored-by: Matt Tarkington <mtarking@cisco.com> * Overlay networks support for eBGP fabric type (#549) * Menaging_overlay_networks_for_eBGP_fabric * Removed extra space * New line inserted * Add support for ipv6 route map under vrf (#563) (#577) * adding support for ipv6 route map under vrf * ipv6 rm * v6_rm_v1 * fixing child fabric attributes * fixing v6VrfRouteMap for ND 4.x * added version checks in the templates Co-authored-by: mkilar123 <mkilar@cisco.com> * Change data model from global to global.ebgp (#580) * Add support for ipv6 route map under vrf (#563) * adding support for ipv6 route map under vrf * ipv6 rm * v6_rm_v1 * fixing child fabric attributes * fixing v6VrfRouteMap for ND 4.x * added version checks in the templates * Migration from global. to global.ebgp. --------- Co-authored-by: mkilar123 <mkilar@cisco.com> * update mvpn vri id range enablement name * updates based on standup meeting * update defaults * Update data_model_keys.py --------- Co-authored-by: Sławomir Kaszlikowski <skaszlik@cisco.com> Co-authored-by: Matt Tarkington <mtarking@cisco.com> Co-authored-by: juburnet <145139118+juburnet@users.noreply.github.com> Co-authored-by: mkilar123 <mkilar@cisco.com>
1 parent 507488c commit 227b251

42 files changed

Lines changed: 827 additions & 96 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

plugins/action/common/nac_dc_validate.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,19 +95,22 @@ def run(self, tmp=None, task_vars=None):
9595
results['data'] = load_yaml_files([mdata])
9696

9797
# Introduce common directory to the rules list by default once vrf and network rules are updated
98-
# rules_to_run.append(f'{rules}common')
9998
parent_keys = ['vxlan', 'fabric']
10099
check = data_model_key_check(results['data'], parent_keys)
101100
if 'fabric' in check['keys_found'] and 'fabric' in check['keys_data']:
102101
if 'type' in results['data']['vxlan']['fabric']:
103102
if results['data']['vxlan']['fabric']['type'] in ('VXLAN_EVPN'):
104103
rules_list.append(f'{rules}ibgp_vxlan/')
104+
rules_list.append(f'{rules}common_vxlan')
105105
elif results['data']['vxlan']['fabric']['type'] in ('MSD', 'MCF'):
106106
rules_list.append(f'{rules}multisite/')
107107
elif results['data']['vxlan']['fabric']['type'] in ('ISN'):
108108
rules_list.append(f'{rules}isn/')
109109
elif results['data']['vxlan']['fabric']['type'] in ('External'):
110110
rules_list.append(f'{rules}external/')
111+
elif results['data']['vxlan']['fabric']['type'] in ('eBGP_VXLAN'):
112+
rules_list.append(f'{rules}ebgp_vxlan/')
113+
rules_list.append(f'{rules}common_vxlan')
111114
else:
112115
results['failed'] = True
113116
results['msg'] = f"vxlan.fabric.type {results['data']['vxlan']['fabric']['type']} is not a supported fabric type."

plugins/action/common/prepare_plugins/prep_003_list_defaults.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ def prepare(self):
203203
#
204204
# There might actualy be data but one of the other model files might
205205
# have a bug or everything except the top level vxlan key is commented out.
206-
if fabric_type in ['VXLAN_EVPN', 'External']:
206+
if fabric_type in ['VXLAN_EVPN', 'External', 'eBGP_VXLAN']:
207207
fn = self.model_data['vxlan']['fabric']['name']
208208
if not bool(self.model_data['vxlan'].get('underlay')):
209209
msg = "((vxlan.underlay)) data is empty! Check your host_vars model data for fabric {fn}."

plugins/action/common/prepare_plugins/prep_105_fabric_overlay.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def prepare(self):
3333
else:
3434
switches = model_data['vxlan']['topology']['switches']
3535

36-
if model_data['vxlan']['fabric']['type'] in ('VXLAN_EVPN'):
36+
if model_data['vxlan']['fabric']['type'] in ('VXLAN_EVPN', 'eBGP_VXLAN'):
3737
# Rebuild sm_data['vxlan']['overlay']['vrf_attach_groups'] into
3838
# a structure that is easier to use.
3939
vrf_grp_name_list = []

plugins/action/dtc/update_switch_hostname_policy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def run(self, tmp=None, task_vars=None):
5050
)
5151

5252
dm_switches = []
53-
if model_data["vxlan"]["fabric"]["type"] in ('VXLAN_EVPN', 'ISN', 'External'):
53+
if model_data["vxlan"]["fabric"]["type"] in ('VXLAN_EVPN', 'eBGP_VXLAN', 'ISN', 'External'):
5454
dm_switches = model_data["vxlan"]["topology"]["switches"]
5555
# elif model_data["vxlan"]["fabric"]["type"] in ('ISN'):
5656
# dm_switches = model_data["vxlan"]["multisite"]["isn"]["topology"]["switches"]

plugins/plugin_utils/data_model_keys.py

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
# from ..helper_functions import do_something
2727

2828
root_key = 'vxlan'
29-
model_keys = {'VXLAN_EVPN': {}, 'MSD': {}, 'MCF': {}, 'ISN': {}, 'External': {}}
29+
model_keys = {'VXLAN_EVPN': {}, 'MSD': {}, 'MCF': {}, 'ISN': {}, 'External': {}, 'eBGP_VXLAN': {}}
3030

3131
# VXLAN_EVPN KEYS
3232
# iBGP VXLAN KEYS
@@ -69,6 +69,45 @@
6969
model_keys['VXLAN_EVPN']['policy.groups'] = [root_key, 'policy', 'groups', 'LIST']
7070
model_keys['VXLAN_EVPN']['policy.switches'] = [root_key, 'policy', 'switches', 'LIST']
7171

72+
# eBGP_VXLAN KEYS
73+
model_keys['eBGP_VXLAN']['global'] = [root_key, 'global', 'KEY']
74+
model_keys['eBGP_VXLAN']['global.ebgp'] = [root_key, 'global', 'ebgp', 'KEY']
75+
model_keys['eBGP_VXLAN']['global.ebgp.dns_servers'] = [root_key, 'global', 'ebgp', 'dns_servers', 'LIST']
76+
model_keys['eBGP_VXLAN']['global.ebgp.ntp_servers'] = [root_key, 'global', 'ebgp', 'ntp_servers', 'LIST']
77+
model_keys['eBGP_VXLAN']['global.ebgp.syslog_servers'] = [root_key, 'global', 'ebgp', 'syslog_servers', 'LIST']
78+
model_keys['eBGP_VXLAN']['global.ebgp.netflow'] = [root_key, 'global', 'ebgp', 'netflow', 'KEY']
79+
model_keys['eBGP_VXLAN']['global.ebgp.netflow.exporter'] = [root_key, 'global', 'ebgp', 'netflow', 'exporter', 'LIST']
80+
model_keys['eBGP_VXLAN']['global.ebgp.netflow.record'] = [root_key, 'global', 'ebgp', 'netflow', 'record', 'LIST']
81+
model_keys['eBGP_VXLAN']['global.ebgp.netflow.monitor'] = [root_key, 'global', 'ebgp', 'netflow', 'monitor', 'LIST']
82+
model_keys['eBGP_VXLAN']['global.ebgp.spanning_tree'] = [root_key, 'global', 'ebgp', 'spanning_tree', 'KEY']
83+
# ---
84+
model_keys['eBGP_VXLAN']['underlay'] = [root_key, 'underlay', 'KEY']
85+
# ---
86+
model_keys['eBGP_VXLAN']['topology'] = [root_key, 'topology', 'KEY']
87+
model_keys['eBGP_VXLAN']['topology.edge_connections'] = [root_key, 'topology', 'edge_connections', 'LIST']
88+
model_keys['eBGP_VXLAN']['topology.fabric_links'] = [root_key, 'topology', 'fabric_links', 'LIST']
89+
model_keys['eBGP_VXLAN']['topology.switches'] = [root_key, 'topology', 'switches', 'LIST']
90+
model_keys['eBGP_VXLAN']['topology.switches.freeform'] = [root_key, 'topology', 'switches', 'freeform', 'LIST_INDEX']
91+
model_keys['eBGP_VXLAN']['topology.switches.interfaces'] = [root_key, 'topology', 'switches', 'interfaces', 'LIST_INDEX']
92+
model_keys['eBGP_VXLAN']['topology.vpc_peers'] = [root_key, 'topology', 'vpc_peers', 'LIST']
93+
# ---
94+
model_keys['eBGP_VXLAN']['overlay'] = [root_key, 'overlay', 'KEY']
95+
model_keys['eBGP_VXLAN']['overlay.vrfs'] = [root_key, 'overlay', 'vrfs', 'LIST']
96+
model_keys['eBGP_VXLAN']['overlay.vrf_attach_groups'] = [root_key, 'overlay', 'vrf_attach_groups', 'LIST']
97+
model_keys['eBGP_VXLAN']['overlay.vrf_attach_groups.switches'] = [root_key, 'overlay', 'vrf_attach_groups', 'switches', 'LIST_INDEX']
98+
model_keys['eBGP_VXLAN']['overlay.networks'] = [root_key, 'overlay', 'networks', 'LIST']
99+
model_keys['eBGP_VXLAN']['overlay.network_attach_groups'] = [root_key, 'overlay', 'network_attach_groups', 'LIST']
100+
model_keys['eBGP_VXLAN']['overlay.network_attach_groups.switches'] = [root_key, 'overlay', 'network_attach_groups', 'switches', 'LIST_INDEX']
101+
# ---
102+
model_keys['eBGP_VXLAN']['overlay_extensions'] = [root_key, 'overlay_extensions', 'KEY']
103+
model_keys['eBGP_VXLAN']['overlay_extensions.route_control'] = [root_key, 'overlay_extensions', 'route_control', 'KEY']
104+
model_keys['eBGP_VXLAN']['overlay_extensions.route_control.route_maps'] = [root_key, 'overlay_extensions', 'route_control', 'route_maps', 'LIST']
105+
# ---
106+
model_keys['eBGP_VXLAN']['policy'] = [root_key, 'policy', 'KEY']
107+
model_keys['eBGP_VXLAN']['policy.policies'] = [root_key, 'policy', 'policies', 'LIST']
108+
model_keys['eBGP_VXLAN']['policy.groups'] = [root_key, 'policy', 'groups', 'LIST']
109+
model_keys['eBGP_VXLAN']['policy.switches'] = [root_key, 'policy', 'switches', 'LIST']
110+
72111
# ISN KEYS
73112

74113
model_keys['ISN']['topology'] = [root_key, 'topology', 'KEY']

roles/dtc/common/tasks/common/ndfc_fabric.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2024 Cisco Systems, Inc. and its affiliates
1+
# Copyright (c) 2025 Cisco Systems, Inc. and its affiliates
22
#
33
# Permission is hereby granted, free of charge, to any person obtaining a copy of
44
# this software and associated documentation files (the "Software"), to deal in

roles/dtc/common/tasks/main.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,27 @@
8484
changes_detected_interface_vpc: false
8585
changes_detected_sub_interface_routed: false
8686
changes_detected_policy: false
87+
vars_common_ebgp_vxlan:
88+
changes_detected_fabric: false
89+
changes_detected_fabric_links: false
90+
changes_detected_edge_connections: false
91+
changes_detected_interface_dot1q: false
92+
changes_detected_interface_access_po: false
93+
changes_detected_interface_access: false
94+
changes_detected_interfaces: false
95+
changes_detected_interface_loopback: false
96+
changes_detected_interface_po_routed: false
97+
changes_detected_interface_routed: false
98+
changes_detected_interface_trunk_po: false
99+
changes_detected_interface_trunk: false
100+
changes_detected_interface_vpc: false
101+
changes_detected_inventory: false
102+
changes_detected_link_vpc_peering: false
103+
changes_detected_networks: false
104+
changes_detected_policy: false
105+
changes_detected_sub_interface_routed: false
106+
changes_detected_vpc_peering: false
107+
changes_detected_vrfs: false
87108
tags: "{{ nac_tags.common_role }}" # Tags defined in roles/common_global/vars/main.yml
88109

89110
- name: Import Role Tasks for iBGP VXLAN Fabric

0 commit comments

Comments
 (0)