clusev/docker/supervisor/supervisord.dev.conf

56 lines
1.5 KiB
Plaintext

[supervisord]
nodaemon=true
user=root
logfile=/dev/null
logfile_maxbytes=0
pidfile=/run/supervisord.pid
[program:php-fpm]
command=php-fpm -F
autorestart=true
startretries=5
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0
[program:nginx]
command=nginx -g 'daemon off;'
autorestart=true
startretries=5
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0
; Vite dev server (HMR) — runs inside the app container, started by Laravel's
; stack, not as a separate compose service. Reachable on :5173.
[program:vite]
command=sh -c "npm install --no-audit --no-fund && exec npm run dev -- --host 0.0.0.0"
directory=/var/www/html
user=app
; supervisord switches uid but does NOT update $HOME — set it explicitly so npm
; can write its cache/logs (otherwise it tries /root/.npm and fails).
environment=HOME="/home/app",USER="app",NPM_CONFIG_CACHE="/home/app/.npm"
autorestart=true
startretries=3
startsecs=10
; Dev metrics emitter (mock CPU+MEM over Reverb) — replaced by the real MetricsPoller (SSH) later.
[program:metrics]
command=php artisan clusev:mock-metrics --interval=2
directory=/var/www/html
user=app
environment=HOME="/home/app",USER="app"
autostart=true
autorestart=true
startsecs=5
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0