feat: add autonomous fiscal control panel

This commit is contained in:
gti
2026-09-22 15:36:12 -03:00
parent 636ed5228b
commit 301aac112e
34 changed files with 1252 additions and 9 deletions
+21
View File
@@ -0,0 +1,21 @@
"""Create a human panel administrator without ever printing the password."""
import getpass
from central.app.db import SessionLocal
from central.app.human_auth import create_admin
def main():
username = input("Admin username: ").strip()
password = getpass.getpass("Admin password (12+ chars): ")
confirmation = getpass.getpass("Confirm password: ")
if password != confirmation:
raise SystemExit("passwords do not match")
with SessionLocal() as session:
admin = create_admin(session, username, password)
print(f"created admin {admin.username}")
if __name__ == "__main__":
main()