[supervisord] nodaemon=true logfile=/tmp/supervisord.log pidfile=/tmp/supervisord.pid [program:postgres] command=/bin/bash -lc "exec /usr/lib/postgresql/15/bin/postgres -D ${PGDATA}" autostart=true autorestart=true startsecs=5 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 priority=10 [program:redis] command=/bin/bash -lc "exec redis-server ${REDIS_DIR}/redis.conf" autostart=true autorestart=true startsecs=3 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 priority=20 [program:sub2api] command=/bin/bash -lc "for i in $(seq 1 60); do pg_isready -h 127.0.0.1 -p 5432 >/dev/null 2>&1 && break; sleep 1; done; if [ -n \"$REDIS_PASSWORD\" ]; then for i in $(seq 1 60); do redis-cli -h 127.0.0.1 -p 6379 -a \"$REDIS_PASSWORD\" ping >/dev/null 2>&1 && break; sleep 1; done; else for i in $(seq 1 60); do redis-cli -h 127.0.0.1 -p 6379 ping >/dev/null 2>&1 && break; sleep 1; done; fi; exec /usr/local/bin/sub2api" autostart=true autorestart=true startsecs=10 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 priority=30 [program:backup-worker] command=/bin/bash -lc "exec /usr/local/bin/backup_worker.sh" autostart=true autorestart=true startsecs=5 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 priority=40