Files
microfish/backend
Kunthawat Greethong 9b0c0da9cb deploy: auto-bootstrap first super_admin on startup (ADMIN_* env)
With this, a fresh deploy provisions its own first super_admin automatically:
after alembic migrations the entrypoint runs scripts/bootstrap_super_admin.py
when ADMIN_EMAIL + ADMIN_PASSWORD are set (idempotent, never overwrites an
existing password; org name/slug optional). This removes the chicken-egg where
login needs a user but no UI/seed could create the very first one.

Optionally runs only when both env vars are present, so an existing deployment
is unaffected. Verified: bash syntax ok; fresh DB produced org+password+
super_admin; re-run left the existing password unchanged.
2026-09-01 14:31:31 +07:00
..
2026-08-31 13:05:21 +07:00
2026-08-31 13:05:21 +07:00