flask-server/docker-entrypoint.sh

10 lines
260 B
Bash
Raw Permalink Normal View History

2024-10-13 04:58:48 -04:00
#!/bin/sh
# Check if the database file exists
if [ ! -f /app/db/movielist.sqlite ]; then
echo "Initializing database..."
python -m flask --app kinolist init-db
fi
# Start the Flask application
exec gunicorn --bind 0.0.0.0:8000 "kinolist:create_app()"