- Add multi-stage Dockerfile (node-builder, composer-builder, production) - Add Nginx config with WebSocket proxy at /_ws path - Add PHP-FPM pool config, php.ini with OPcache tuning - Add Supervisord managing 7 processes: php-fpm, nginx, horizon, scheduler, reverb, pulse-check, pulse-work - Add entrypoint.sh with auto-migration, config caching, storage setup - Add .dockerignore and .env.production.example - Install laravel/horizon for production queue management and dashboard - Install laravel/pulse for production monitoring with Reverb integration - Configure TrustProxies middleware for HTTPS behind Traefik - Add horizon:snapshot to scheduler - Add VITE_REVERB_PATH for WebSocket path routing through Nginx
84 lines
1.7 KiB
Plaintext
84 lines
1.7 KiB
Plaintext
[supervisord]
|
|
nodaemon=true
|
|
user=root
|
|
logfile=/dev/null
|
|
logfile_maxbytes=0
|
|
|
|
[program:php-fpm]
|
|
command=php-fpm --nodaemonize --fpm-config /usr/local/etc/php-fpm.d/www.conf
|
|
autostart=true
|
|
autorestart=true
|
|
priority=5
|
|
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
|
|
priority=10
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
|
|
[program:horizon]
|
|
command=php /var/www/html/artisan horizon
|
|
user=www-data
|
|
autostart=true
|
|
autorestart=true
|
|
priority=15
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
stopwaitsecs=3600
|
|
|
|
[program:scheduler]
|
|
command=/bin/sh -c "while sleep 60; do php /var/www/html/artisan schedule:run; done"
|
|
user=www-data
|
|
autostart=true
|
|
autorestart=true
|
|
priority=20
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
|
|
[program:reverb]
|
|
command=php /var/www/html/artisan reverb:start --host=0.0.0.0 --port=8080
|
|
user=www-data
|
|
autostart=true
|
|
autorestart=true
|
|
priority=25
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
|
|
[program:pulse-check]
|
|
command=php /var/www/html/artisan pulse:check
|
|
user=www-data
|
|
autostart=true
|
|
autorestart=true
|
|
priority=30
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
stopwaitsecs=3600
|
|
|
|
[program:pulse-work]
|
|
command=php /var/www/html/artisan pulse:work
|
|
user=www-data
|
|
autostart=true
|
|
autorestart=true
|
|
priority=35
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
stopwaitsecs=3600
|