mirror of
https://github.com/jez500/pricebuddy.git
synced 2026-11-24 19:58:13 +01:00
apachectl reads /var/run/apache2/apache2.pid. After an unclean restart another process can reuse the old PID, and apachectl then exits 0 without starting Apache. apache2-foreground removes the stale PID file first. Supervisor now also restarts Apache if it exits.
35 lines
813 B
Plaintext
Executable File
35 lines
813 B
Plaintext
Executable File
[supervisord]
|
|
nodaemon = true
|
|
logfile = /dev/null
|
|
logfile_maxbytes = 0
|
|
pidfile = /run/supervisord.pid
|
|
|
|
[program:apache2]
|
|
; apache2-foreground removes a stale PID file before it starts Apache. apachectl
|
|
; reads that file, and when another process reuses the old PID it exits 0 without
|
|
; starting Apache (#217).
|
|
command=/usr/local/bin/apache2-foreground
|
|
redirect_stderr=true
|
|
autostart=true
|
|
autorestart=true
|
|
|
|
[program:cron]
|
|
command = /start-cron.sh
|
|
stdout_logfile = /var/log/cron.log
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile = /var/log/cron.log
|
|
stderr_logfile_maxbytes=0
|
|
user = root
|
|
autostart = true
|
|
autorestart = true
|
|
priority = 20
|
|
|
|
[program:queue-worker]
|
|
command=php artisan queue:work
|
|
autostart = true
|
|
autorestart = true
|
|
priority = 30
|
|
redirect_stderr = true
|
|
stdout_logfile = /dev/fd/1
|
|
stdout_logfile_maxbytes = 0
|