Add auth bootstrap and database safeguards

This commit is contained in:
JB
2026-07-24 22:12:52 -04:00
parent 8a0bfd2187
commit b430a291fa
22 changed files with 380 additions and 62 deletions
+10 -4
View File
@@ -1,10 +1,16 @@
# Local path used by the embedded @tursodatabase/database engine.
# Relative paths are resolved from the project directory.
TDR_DATABASE_PATH=./data/shd-build.db
# Relative paths are resolved from the project directory. Development and
# production should always use different database files.
TDR_DATABASE_PATH=./data/shd-build-development.db
# Optional fixed credentials used only when initializing or explicitly resetting
# the two default accounts. Leave blank to generate secure temporary passwords.
DEFAULT_ADMIN_PASSWORD=
DEFAULT_USER_PASSWORD=
# Discord OAuth2 application credentials.
DISCORD_CLIENT_ID=
DISCORD_CLIENT_SECRET=
# Local: http://localhost:5173/auth/discord/callback
# Proxied development: https://dev.shd.build/auth/discord/callback
# Production: https://shd.build/auth/discord/callback
DISCORD_REDIRECT_URI=http://localhost:5173/auth/discord/callback
DISCORD_REDIRECT_URI=https://dev.shd.build/auth/discord/callback