diff --git a/entrypoint b/entrypoint index ea271cb4..7e239949 100644 --- a/entrypoint +++ b/entrypoint @@ -36,4 +36,4 @@ until postgres_ready; do done >&2 echo 'PostgreSQL is available' -exec "$@" +exec "/start" diff --git a/start b/start index 514ec5c3..c879b1d2 100644 --- a/start +++ b/start @@ -6,6 +6,7 @@ set -o nounset python /app/manage.py collectstatic --noinput +python /app/manage.py migrate python /app/manage.py createcachetable compress_enabled() { @@ -28,4 +29,4 @@ if compress_enabled; then python /app/manage.py compress fi -/usr/local/bin/gunicorn config.asgi --bind 0.0.0.0:5000 --chdir=/app -k uvicorn.workers.UvicornWorker +/usr/local/bin/gunicorn config.asgi --bind 0.0.0.0:$PORT --chdir=/app -k uvicorn.workers.UvicornWorker