refactor(odeme): update environment variable usage and documentation
All checks were successful
Deploy / deploy (push) Successful in 8m39s

Replaced `NEXT_PUBLIC_APP_URL` with `APP_URL` in the payment processing logic to ensure proper runtime access. Updated related documentation to clarify the distinction between build-time and runtime environment variables, emphasizing the importance of using `APP_URL` for callback and webhook URLs. Adjusted references in the codebase to reflect this change, enhancing clarity and functionality in the payment flow.
This commit is contained in:
bilalgursen
2026-08-11 11:42:47 +03:00
parent d03ba91bf0
commit 951caa3c93
6 changed files with 47 additions and 9 deletions

View File

@@ -18,7 +18,10 @@ jobs:
cat > .env.production <<'EOF'
BETTER_AUTH_SECRET=${{ secrets.BETTER_AUTH_SECRET }}
BETTER_AUTH_URL=${{ secrets.BETTER_AUTH_URL }}
NEXT_PUBLIC_APP_URL=${{ secrets.NEXT_PUBLIC_APP_URL }}
# Ödeme callback/yönlendirme kökü. Public önekli DEĞİL: build'e değil
# runtime'a geçmesi gerekiyor (bkz. src/lib/app-url.ts). Secret adı
# geçmişten NEXT_PUBLIC_APP_URL, değeri aynı https kök adres.
APP_URL=${{ secrets.NEXT_PUBLIC_APP_URL }}
GOOGLE_CLIENT_ID=${{ secrets.GOOGLE_CLIENT_ID }}
GOOGLE_CLIENT_SECRET=${{ secrets.GOOGLE_CLIENT_SECRET }}
RESEND_API_KEY=${{ secrets.RESEND_API_KEY }}