Spaces:
Sleeping
Sleeping
Harshit Ghosh commited on
Commit ·
20d5ed3
1
Parent(s): 3754bec
Fix 500: run db migrations in start.sh before gunicorn
Browse files7 unmodified lines89101112137 unmodified lines# Trap SIGTERM and SIGINT for graceful shutdowntrap "kill $CELERY_PID; exit 0" SIGTERM SIGINT# Start Gunicorn in foreground# Hugging Face Spaces expects the app to listen on port 7860gunicorn -w 4 -b 0.0.0.0:${PORT:-7860} app_new:app7 unmodified lines89101112131415167 unmodified lines# Trap SIGTERM and SIGINT for graceful shutdowntrap "kill $CELERY_PID; exit 0" SIGTERM SIGINT# Run database migrations/initializationflask --app app_new init-db-cmd# Start Gunicorn in foreground# Hugging Face Spaces expects the app to listen on port 7860gunicorn -w 4 -b 0.0.0.0:${PORT:-7860} app_new:app
start.sh+3