Spaces:
Runtime error
Runtime error
| set -e | |
| cd /app/videocaller | |
| echo "=== Collecting static files ===" | |
| python manage.py collectstatic --noinput | |
| echo "=== Running database migrations ===" | |
| python manage.py migrate --noinput | |
| # Start Django-Q worker in background only if Redis is configured. | |
| # Without REDIS_URL the Q_CLUSTER falls back to the ORM broker (database-backed). | |
| if [ -n "$REDIS_URL" ]; then | |
| echo "=== Starting Django-Q worker (Redis broker) ===" | |
| python manage.py qcluster & | |
| echo "Worker started with PID $!" | |
| else | |
| echo "=== No REDIS_URL set — starting Django-Q worker with ORM broker ===" | |
| python manage.py qcluster & | |
| echo "Worker started with PID $!" | |
| fi | |
| echo "=== Starting Daphne ASGI server on 0.0.0.0:7860 ===" | |
| exec daphne -b 0.0.0.0 -p 7860 videocaller.asgi:application | |