![google-labs-jules[bot]](/assets/img/avatar_default.png)
This commit addresses an issue where you, when clicking the "Continue with Google" button, were redirected back to the login page instead of to Google's authentication page. The following changes were made: 1. **Frontend Redirect:** * Modified `fe/src/components/SocialLoginButtons.vue` to make the "Continue with Google" button redirect to the correct backend API endpoint (`/auth/google/login`) using the configured `API_BASE_URL`. 2. **Backend Route Confirmation:** * Verified that the backend OAuth routes in `be/app/api/auth/oauth.py` are correctly included in `be/app/main.py` under the `/auth` prefix, making them accessible. 3. **OAuth Credentials Configuration:** * Added `GOOGLE_CLIENT_ID` and `GOOGLE_CLIENT_SECRET` placeholders to `env.production.template` to guide you in setting up your OAuth credentials. * Added instructional comments in `be/app/config.py` regarding the necessity of these environment variables and the correct configuration of `GOOGLE_REDIRECT_URI`. With these changes, and assuming the necessary Google Cloud OAuth credentials (Client ID, Client Secret) and redirect URIs are correctly configured in the environment, the Google OAuth flow should now function as expected.
46 lines
1.5 KiB
Plaintext
46 lines
1.5 KiB
Plaintext
# Production Environment Variables Template
|
|
# Copy this file to .env.production and fill in the actual values
|
|
# NEVER commit the actual .env.production file to version control
|
|
|
|
# Database Configuration
|
|
POSTGRES_USER=mitlist_user
|
|
POSTGRES_PASSWORD=your_secure_database_password_here
|
|
POSTGRES_DB=mitlist_prod
|
|
DATABASE_URL=postgresql+asyncpg://mitlist_user:your_secure_database_password_here@db:5432/mitlist_prod
|
|
|
|
# Security Keys (Generate with: openssl rand -hex 32)
|
|
SECRET_KEY=your_secret_key_here_minimum_32_characters_long
|
|
SESSION_SECRET_KEY=your_session_secret_key_here_minimum_32_characters_long
|
|
|
|
# API Keys
|
|
GEMINI_API_KEY=your_gemini_api_key_here
|
|
|
|
# Redis Configuration
|
|
REDIS_PASSWORD=your_redis_password_here
|
|
|
|
# Sentry Configuration (Optional but recommended)
|
|
SENTRY_DSN=your_sentry_dsn_here
|
|
|
|
# CORS Configuration
|
|
CORS_ORIGINS=https://yourdomain.com,https://www.yourdomain.com
|
|
FRONTEND_URL=https://yourdomain.com
|
|
|
|
# Frontend Build Variables
|
|
VITE_API_URL=https://yourdomain.com/api
|
|
VITE_SENTRY_DSN=your_frontend_sentry_dsn_here
|
|
VITE_ROUTER_MODE=history
|
|
|
|
# Google OAuth Configuration - Replace with your actual credentials
|
|
GOOGLE_CLIENT_ID="YOUR_GOOGLE_CLIENT_ID_HERE"
|
|
GOOGLE_CLIENT_SECRET="YOUR_GOOGLE_CLIENT_SECRET_HERE"
|
|
GOOGLE_REDIRECT_URI=https://yourdomain.com/auth/google/callback
|
|
|
|
APPLE_CLIENT_ID=your_apple_client_id
|
|
APPLE_TEAM_ID=your_apple_team_id
|
|
APPLE_KEY_ID=your_apple_key_id
|
|
APPLE_PRIVATE_KEY=your_apple_private_key
|
|
APPLE_REDIRECT_URI=https://yourdomain.com/auth/apple/callback
|
|
|
|
# Production Settings
|
|
ENVIRONMENT=production
|
|
LOG_LEVEL=INFO |