38086-vm/entrypoint.sh
2026-02-07 18:11:53 +00:00

15 lines
471 B
Bash

#!/bin/bash
set -e
echo "Starting deployment script..."
echo "Collecting static files..."
# Run collectstatic but allow it to fail without crashing the container immediately,
# so we can see the logs if something goes wrong.
python manage.py collectstatic --noinput || echo "WARNING: collectstatic failed! Check static files."
echo "Applying migrations..."
python manage.py migrate
echo "Starting Gunicorn..."
exec gunicorn config.wsgi:application --bind 0.0.0.0:8000