Skip to content

Commit 7e52ef9

Browse files
authored
Stop/Start restapi server upon config reload (sonic-net#911)
1 parent c0f5884 commit 7e52ef9

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

config/main.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,7 @@ def _abort_if_false(ctx, param, value):
545545
def _stop_services():
546546
# on Mellanox platform pmon is stopped by syncd
547547
services_to_stop = [
548+
'restapi',
548549
'swss',
549550
'lldp',
550551
'pmon',
@@ -575,7 +576,8 @@ def _reset_failed_services():
575576
'syncd',
576577
'teamd',
577578
'nat',
578-
'sflow'
579+
'sflow',
580+
'restapi'
579581
]
580582
execute_systemctl(services_to_reset, SYSTEMCTL_ACTION_RESET_FAILED)
581583

@@ -595,6 +597,7 @@ def _restart_services():
595597
'hostcfgd',
596598
'nat',
597599
'sflow',
600+
'restapi'
598601
]
599602

600603
if asic_type == 'mellanox' and 'pmon' in services_to_restart:

0 commit comments

Comments
 (0)