Add more logging
This commit is contained in:
@@ -6,6 +6,7 @@ from dotenv import load_dotenv
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
from lib.helpers import hash_password
|
from lib.helpers import hash_password
|
||||||
|
from lib.logger import logger
|
||||||
|
|
||||||
load_dotenv()
|
load_dotenv()
|
||||||
|
|
||||||
@@ -61,6 +62,9 @@ def seed_db() -> None:
|
|||||||
# Seed Admin users
|
# Seed Admin users
|
||||||
admin_username = os.getenv("ADMIN_USERNAME")
|
admin_username = os.getenv("ADMIN_USERNAME")
|
||||||
hashed_admin_password = hash_password(os.getenv("ADMIN_PASSWORD", "password"))
|
hashed_admin_password = hash_password(os.getenv("ADMIN_PASSWORD", "password"))
|
||||||
|
logger.debug(
|
||||||
|
f"Admin user: {admin_username}, hashed password: {hashed_admin_password}"
|
||||||
|
)
|
||||||
with get_connection() as conn:
|
with get_connection() as conn:
|
||||||
conn.execute(
|
conn.execute(
|
||||||
'INSERT INTO "User" (username, hashed_password, team_id, is_active, is_admin) VALUES (?, ?, ?, ?, ?)',
|
'INSERT INTO "User" (username, hashed_password, team_id, is_active, is_admin) VALUES (?, ?, ?, ?, ?)',
|
||||||
|
|||||||
Reference in New Issue
Block a user