Enhance admin bootstrap process with reset functionality
- Update .env.example and README.md to include new ADMIN_BOOTSTRAP_RESET option for resetting admin credentials on startup. - Modify main.py to implement logic for resetting the admin's password, role, and status if ADMIN_BOOTSTRAP_RESET is set to true. - Adjust config.py to define the new setting, ensuring proper configuration management.
This commit is contained in:
@@ -13,3 +13,8 @@ COOKIE_SECURE=false
|
||||
# Auf true setzen, wenn hinter HTTPS/TLS-Terminierung (Reverse Proxy)
|
||||
ADMIN_BOOTSTRAP_EMAIL=admin@internal.local
|
||||
ADMIN_BOOTSTRAP_PASSWORD=ChangeMe123!
|
||||
# true = setzt Passwort/Rolle/Status des Bootstrap-Admins bei jedem Start
|
||||
# auf die obigen Werte zurueck (auch wenn der User schon existiert).
|
||||
# Nach erfolgreichem Login wieder auf false setzen, damit UI-Passwortaenderungen
|
||||
# nicht beim naechsten Neustart ueberschrieben werden.
|
||||
ADMIN_BOOTSTRAP_RESET=false
|
||||
|
||||
Reference in New Issue
Block a user