[supervisord] nodaemon=true user=root logfile=/dev/null logfile_maxbytes=0 pidfile=/run/supervisord.pid # Both programs log to the container's stdout/stderr so `docker logs` and the # Dokploy log viewer show everything without shelling into the container. [program:php-fpm] command=php-fpm --nodaemonize --force-stderr autostart=true autorestart=true startretries=3 priority=10 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 [program:nginx] command=nginx -g "daemon off;" autostart=true autorestart=true startretries=3 priority=20 stdout_logfile=/dev/stdout stdout_logfile_maxbytes=0 stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 # If either process dies for good, take the whole container down so Docker's # restart policy (and Dokploy's health check) can react. Without this the # container stays "up" while serving nothing. [eventlistener:process_exit] command=bash -c "printf 'READY\\n'; while read -r line; do echo \"Process exited: $line\" >&2; kill -SIGTERM $PPID; done < /dev/stdin" events=PROCESS_STATE_FATAL