Fix auth deploy: env after pull, sidebar without asChild.

AUTH_JWT_SECRET was never written because upsert ran before git pull;
sidebar used Button asChild which Base UI does not support.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-11 15:45:59 +02:00
co-authored by Cursor
parent 5a69b380da
commit 2405093bbb
2 changed files with 28 additions and 19 deletions
+7 -7
View File
@@ -118,13 +118,6 @@ upsert_env NEXT_PUBLIC_API_URL "$SITE" .env
# JSON list — keep it a single line so docker compose / pydantic-settings parse it.
upsert_env CORS_ORIGINS "[\"$SITE\"]" .env
# Self-host multi-user auth (Pinscope accounts). Generate a secret once if missing.
if [[ -z "$(read_env AUTH_JWT_SECRET .env || true)" ]]; then
log "Generating AUTH_JWT_SECRET for local multi-user auth"
upsert_env AUTH_JWT_SECRET "$(openssl rand -hex 32)" .env
fi
upsert_env NEXT_PUBLIC_AUTH_MODE "local" .env
KEY="$(read_env DEEPSEEK_API_KEY .env || true)"
if [[ -z "$KEY" || "$KEY" == "sk-..." ]]; then
die "Set a real DEEPSEEK_API_KEY in $ROOT/.env before updating."
@@ -144,6 +137,13 @@ else
log "Skipping git pull (--no-pull)"
fi
# Self-host multi-user auth — after pull so this script's upsert logic is current.
if [[ -z "$(read_env AUTH_JWT_SECRET .env || true)" ]]; then
log "Generating AUTH_JWT_SECRET for local multi-user auth"
upsert_env AUTH_JWT_SECRET "$(openssl rand -hex 32)" .env
fi
upsert_env NEXT_PUBLIC_AUTH_MODE "local" .env
log "docker compose up -d --build (data/ is kept)"
compose up -d --build