Skip to content

Commit

Permalink
[restapi]: Don't use python/python2 for restapi start scripts (#10285)
Browse files Browse the repository at this point in the history
Python 2 isn't installed by default in Buster and Bullseye containers,
and the scripts/modules can be used with Python 3, so make sure Python 3
is used.

Why I did it
After the Buster and Bullseye upgrade for the restapi container, processes will no longer start because supervisord is trying to call python and python2, both of which are unavailable.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
  • Loading branch information
saiarcot895 authored and pull[bot] committed Aug 19, 2024
1 parent ffdb7ae commit 046bdd0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dockers/docker-sonic-restapi/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ logfile_backups=2
nodaemon=true

[eventlistener:dependent-startup]
command=python -m supervisord_dependent_startup
command=python3 -m supervisord_dependent_startup
autostart=true
autorestart=unexpected
startretries=0
Expand All @@ -13,7 +13,7 @@ events=PROCESS_STATE
buffer_size=1024

[eventlistener:supervisor-proc-exit-listener]
command=python2 /usr/bin/supervisor-proc-exit-listener --container-name restapi
command=/usr/bin/supervisor-proc-exit-listener --container-name restapi
events=PROCESS_STATE_EXITED,PROCESS_STATE_RUNNING
autostart=true
autorestart=false
Expand Down

0 comments on commit 046bdd0

Please sign in to comment.