Found by running the container on Docker Desktop. Disable gunicorn's control socket (the home directory is read-only) and ignore __pycache__ and .pyc at any depth so host bytecode with the Windows source path stays out of the image. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Sk72AxLwQnYttF6VFSxQLt
14 lines
256 B
Bash
14 lines
256 B
Bash
#!/bin/sh
|
|
set -eu
|
|
|
|
python manage.py migrate --noinput
|
|
|
|
exec gunicorn portal.config.wsgi:application \
|
|
--bind 0.0.0.0:8000 \
|
|
--workers 1 \
|
|
--threads 4 \
|
|
--preload \
|
|
--worker-tmp-dir /tmp \
|
|
--error-logfile - \
|
|
--no-control-socket
|