# run the server in supervisor # supervisord -c /etc/supervisor/supervisor.conf # stop the server in supervisor # supervisorctl -c /etc/supervisor/supervisor.conf stop all # install the supervisor # apt-get install -y supervisor [program:sdif_http_server] directory=/home/lee/code/sdif command=GOOGLE_APPLICATION_CREDENTIALS=secrets/google-credentials.json PYTHONPATH=. uvicorn --port 8000 --timeout-keep-alive 600 --workers 1 --backlog 1 --limit-concurrency 4 main:app autostart=true autorestart=true environment=VIRTUAL_ENV="/home/lee/code/sdif/.env/",PATH="/opt/app/sdif/.env/bin",\ HOME="/home/lee",GOOGLE_APPLICATION_CREDENTIALS="secrets/google-credentials.json",PYTHONPATH='/home/lee/code/sdif' stdout_logfile=syslog stderr_logfile=syslog