run migrations automatically on backend startup (AUTO_MIGRATIONS)

Add a migrate.sh config (ported from lasuite-docs) that the backend
entrypoint runs when AUTO_MIGRATIONS=true (default). It loads secrets,
waits for the DB, and idempotently applies pending migrations via
'migrate --check' then 'migrate --noinput'. The manual 'abra app cmd
backend migrate' now delegates to the same script.
This commit is contained in:
notplants
2026-06-23 19:13:39 +00:00
committed by notplants
parent d3c3682936
commit 0b64135f98
5 changed files with 45 additions and 4 deletions

View File

@ -68,6 +68,12 @@ LOGGING_LEVEL_HANDLERS_CONSOLE=INFO
LOGGING_LEVEL_LOGGERS_ROOT=INFO
LOGGING_LEVEL_LOGGERS_APP=INFO
##############################################################################
# MIGRATIONS
##############################################################################
# Set to false to disable automatic migrations on backend startup
# AUTO_MIGRATIONS=true
##############################################################################
# COLLABORA ADMIN PANEL
##############################################################################