Files
Moon-Household-Budget/entrypoint.sh
2026-06-06 19:12:43 -05:00

20 lines
588 B
Bash

#!/bin/sh
# Runs before the app starts. Ensures the data dir exists and runs DB
# migrations if the app uses them. Uncomment the lines that apply.
set -e
mkdir -p /data/uploads/suggestions
# --- Database migrations (pick what the app uses, leave the rest commented) ---
# Flask-Migrate / Alembic via Flask:
# flask db upgrade
# Raw Alembic:
# alembic upgrade head
# Django:
# python manage.py migrate --noinput
# python manage.py collectstatic --noinput
# Plain SQLite with a schema file (only first run):
# [ -f /data/app.db ] || sqlite3 /data/app.db < schema.sql
exec "$@"