We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f499fbd commit 38e834aCopy full SHA for 38e834a
1 file changed
backend/entrypoint.sh
@@ -1,11 +1,14 @@
1
#!/bin/sh
2
-set -e
+
3
+echo "=== ENTRYPOINT START ==="
4
+echo "PORT: ${PORT:-8000}"
5
+echo "DATABASE_URL set: $(if [ -n "$DATABASE_URL" ]; then echo 'yes'; else echo 'NO!'; fi)"
6
7
echo "Running database migrations..."
-alembic upgrade head
8
+alembic upgrade head || { echo "Migration failed!"; exit 1; }
9
10
echo "Seeding database..."
-python scripts/seed_data.py || echo "Seed already exists or failed (continuing...)"
11
+python scripts/seed_data.py || echo "Seed skipped or failed (continuing...)"
12
-echo "Starting server..."
13
+echo "Starting server on port ${PORT:-8000}..."
14
exec uvicorn app.main:app --host 0.0.0.0 --port ${PORT:-8000}
0 commit comments