fix: enhance OAuth configuration and add debugging - Add Google OAuth authorization parameters - Add environment variable validation - Add debugging logs for redirect callback - Create OAuth configuration check script

This commit is contained in:
theshy
2025-08-01 20:42:03 +08:00
parent 2cd0ebda65
commit e955f4c317
8 changed files with 195 additions and 358 deletions

19
env.production.example Normal file
View File

@ -0,0 +1,19 @@
# Database
DATABASE_URL="file:./prod.db"
# NextAuth.js - 生产环境配置
NEXTAUTH_URL="https://recorder.zyj.best"
NEXTAUTH_SECRET="your-production-nextauth-secret"
# Google OAuth - 生产环境配置
GOOGLE_CLIENT_ID="your-google-client-id"
GOOGLE_CLIENT_SECRET="your-google-client-secret"
# AWS S3 Configuration
AWS_ACCESS_KEY_ID="your-aws-access-key-id"
AWS_SECRET_ACCESS_KEY="your-aws-secret-access-key"
AWS_REGION="us-east-1"
AWS_S3_BUCKET="your-s3-bucket-name"
# 生产环境设置
NODE_ENV="production"