1
0
forked from baron/baron-sso

callback 검증 보강. seed-tenant 추가보강

This commit is contained in:
2026-05-11 11:03:11 +09:00
parent f46a7cc088
commit 9a64a16cb9
28 changed files with 2832 additions and 133 deletions

View File

@@ -3,6 +3,19 @@ set -eu
app_env="$(printf '%s' "${APP_ENV:-development}" | tr '[:upper:]' '[:lower:]')"
if [ -z "${VITE_ORGFRONT_PUBLIC_URL:-}" ] && [ -n "${ORGFRONT_URL:-}" ]; then
export VITE_ORGFRONT_PUBLIC_URL="$ORGFRONT_URL"
fi
if [ -z "${VITE_ORGFRONT_PUBLIC_URL:-}" ] && [ -n "${ORGFRONT_CALLBACK_URLS:-}" ]; then
first_orgfront_callback="${ORGFRONT_CALLBACK_URLS%%,*}"
case "$first_orgfront_callback" in
http://*/auth/callback | https://*/auth/callback)
export VITE_ORGFRONT_PUBLIC_URL="${first_orgfront_callback%/auth/callback}"
;;
esac
fi
case "$app_env" in
production|prod|stage|staging)
mode="production"
@@ -12,6 +25,11 @@ case "$app_env" in
;;
esac
if [ "${1:-}" = "--print-public-url" ]; then
printf '%s\n' "${VITE_ORGFRONT_PUBLIC_URL:-}"
exit 0
fi
if [ "${1:-}" = "--print-mode" ]; then
printf '%s\n' "$mode"
exit 0