49 lines
1.4 KiB
Plaintext
49 lines
1.4 KiB
Plaintext
# Shared supervisord configuration for both Docker image variants.
|
|
# The single-container image appends supervisord.surrealdb.conf to this file
|
|
# at build time (see the `single` stage in the Dockerfile).
|
|
|
|
[supervisord]
|
|
nodaemon=true
|
|
logfile=/dev/stdout
|
|
logfile_maxbytes=0
|
|
pidfile=/tmp/supervisord.pid
|
|
|
|
[program:api]
|
|
command=uv run --no-sync uvicorn api.main:app --host %(ENV_API_HOST)s --port 5055
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
autorestart=true
|
|
priority=10
|
|
autostart=true
|
|
startsecs=3
|
|
|
|
[program:worker]
|
|
command=uv run --no-sync surreal-commands-worker --import-modules commands
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
autorestart=true
|
|
priority=20
|
|
autostart=true
|
|
startsecs=3
|
|
|
|
[program:frontend]
|
|
; HOSTNAME must be forced here: container runtimes inject HOSTNAME=<container/pod
|
|
; hostname> at runtime (Podman pods override the image's ENV HOSTNAME=0.0.0.0),
|
|
; making Next.js bind to the wrong address (#994). Override with FRONTEND_BIND_HOST.
|
|
command=bash -c "/app/scripts/wait-for-api.sh && HOSTNAME=${FRONTEND_BIND_HOST:-0.0.0.0} node server.js"
|
|
directory=/app/frontend
|
|
environment=NODE_ENV="production",PORT="8502"
|
|
passenv=API_URL,NEXT_PUBLIC_API_URL,INTERNAL_API_URL
|
|
stdout_logfile=/dev/stdout
|
|
stdout_logfile_maxbytes=0
|
|
stderr_logfile=/dev/stderr
|
|
stderr_logfile_maxbytes=0
|
|
autorestart=true
|
|
priority=30
|
|
autostart=true
|
|
startsecs=10
|