- Ensure authentication is enabled by setting the following environment variable:
ADMYRAL_DISABLE_AUTH=false
- Go to Google Cloud console
- Go to APIs & Services
- Set up your OAuth Consent Screen
- Click on Credentials tab
- Click Create Credentials button and select OAuth client id
-
select as application type: Web application
-
add the following "Authorized redirect URIs":
- For production:
https://{YOUR_DOMAIN}/api/auth/callback/google
- For development:
http://localhost:3000/api/auth/callback/google
- For production:
-
Save the Client ID and Client Secret in your environment file:
# .env ADMYRAL_DISABLE_AUTH=false AUTH_GOOGLE_ID=your_google_client_id AUTH_GOOGLE_SECRET=your_google_client_secret