mirror of
https://github.com/fsecada01/Pygentic-AI.git
synced 2026-05-12 12:15:00 +00:00
Gunicorn crashes on container start when these env vars are missing from stack.env — -w receives no argument and exits immediately. Defaults now match .env.example values (WORKERS=4, TIMEOUT=120, PORT=5051), consistent with the bash default syntax already used in compose.yaml. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
12 lines
328 B
Bash
Executable File
12 lines
328 B
Bash
Executable File
#!/bin/bash
|
|
|
|
__dir="$(cd -P -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd -P)"
|
|
cd ${__dir}/../../ || exit
|
|
source .venv/bin/activate
|
|
cd src || exit
|
|
# python -m backend.utils
|
|
gunicorn main:app -w ${WORKERS:-4} -k uvicorn.workers.UvicornWorker \
|
|
--timeout "${TIMEOUT:-120}" \
|
|
--forwarded-allow-ips "*" \
|
|
-b 0.0.0.0:"${PORT:-5051}"
|