summaryrefslogtreecommitdiff
path: root/src/conf_mode/protocols_bgp.py
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-10-06 15:17:17 +0200
committerChristian Breunig <christian@breunig.cc>2024-12-16 22:21:36 +0100
commit81923562a8a164f7ff9761e976c20420a585907a (patch)
tree8fe525e8ab4bb0d07f9eb52b52816e50bcb956cf /src/conf_mode/protocols_bgp.py
parent7538fd4c518271a517b6753dd664fd07cd86bddd (diff)
downloadvyos-1x-81923562a8a164f7ff9761e976c20420a585907a.tar.gz
vyos-1x-81923562a8a164f7ff9761e976c20420a585907a.zip
frr: T6747: make daemon definitions re-usable for both conf-mode and smoketests
Diffstat (limited to 'src/conf_mode/protocols_bgp.py')
-rwxr-xr-xsrc/conf_mode/protocols_bgp.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/conf_mode/protocols_bgp.py b/src/conf_mode/protocols_bgp.py
index 22f020099..e5c46aee6 100755
--- a/src/conf_mode/protocols_bgp.py
+++ b/src/conf_mode/protocols_bgp.py
@@ -617,8 +617,6 @@ def apply(bgp):
if {'vrf', 'vni'} <= set(bgp):
call('vtysh -c "conf t" -c "vrf {vrf}" -c "no vni {vni}"'.format(**bgp))
- bgp_daemon = 'bgpd'
-
# Save original configuration prior to starting any commit actions
frr_cfg = frr.FRRConfig()
@@ -628,7 +626,7 @@ def apply(bgp):
if 'vrf' in bgp:
vrf = ' vrf ' + bgp['vrf']
- frr_cfg.load_configuration(bgp_daemon)
+ frr_cfg.load_configuration(frr.bgp_daemon)
# Remove interface specific config
for key in ['interface', 'interface_removed']:
@@ -640,7 +638,7 @@ def apply(bgp):
frr_cfg.modify_section(f'^router bgp \d+{vrf}', stop_pattern='^exit', remove_stop_mark=True)
if 'frr_bgpd_config' in bgp:
frr_cfg.add_before(frr.default_add_before, bgp['frr_bgpd_config'])
- frr_cfg.commit_configuration(bgp_daemon)
+ frr_cfg.commit_configuration(frr.bgp_daemon)
return None