Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/sonic-frr-mgmt-framework/frrcfgd/frrcfgd.py
Original file line number Diff line number Diff line change
Expand Up @@ -1760,7 +1760,6 @@ class BGPConfigDaemon:
DEFAULT_VRF = 'default'

global_key_map = [('router_id', '{no:no-prefix}bgp router-id {}'),
('srv6_locator', '{no:no-prefix}srv6-locator {}'),
(['load_balance_mp_relax', '+as_path_mp_as_set'], '{no:no-prefix}bgp bestpath as-path multipath-relax {:mp-as-set}', ['true', 'false']),
('always_compare_med', '{no:no-prefix}bgp always-compare-med', ['true', 'false']),
('external_compare_router_id', '{no:no-prefix}bgp bestpath compare-routerid', ['true', 'false']),
Expand Down Expand Up @@ -2689,6 +2688,14 @@ def __update_bgp(self, data_list):
syslog.syslog(syslog.LOG_ERR, 'local ASN for VRF %s was not configured' % vrf)
continue
cmd_prefix = ['configure terminal', 'router bgp {} vrf {}'.format(local_asn, vrf)]
if 'srv6_locator' in data:
cmd = "vtysh -c 'configure terminal' "
cmd += " -c 'router bgp {} vrf {}' ".format(local_asn, vrf)
cmd += " -c 'segment-routing srv6' "
cmd += " -c 'locator {}' ".format(data['srv6_locator'].data)
if not self.__run_command(table, cmd):
syslog.syslog(syslog.LOG_ERR, 'failed running SRV6 POLICY config command')
continue
if not key_map.run_command(self, table, data, cmd_prefix):
syslog.syslog(syslog.LOG_ERR, 'failed running BGP global config command')
continue
Expand Down
Loading