Deployment in GCP with Google Identity
This document assumes the use of the following:
- Cloud provider: Google Cloud Platform (GCP)
- Kubernetes service: Google Kubernetes Engine (GKE)
- Ingress Controller: GKE Ingress Controller
- Identity Provider (IdP): Google Identity (Google Workspace)
- (Optional) cert-manager (to manage TLS certificates)
- (Optional) ExternalDNS (to synchronize ingresses with the DNS service)
Configuring Patronus AI to use Google Identity as an Identity Provider
Configuring Google Identity
-
Go to Google Cloud Console, select your project and navigate to APIs & Services > Credentials.
-
Click on Create Credentials and select OAuth client ID.
-
If prompted, configure the OAuth consent screen first:
- Select Internal for user type (if using Google Workspace) or External for other cases
- Fill in the required application information
- Add the necessary scopes (email, profile, openid)
- Save and continue
-
Back in the credentials creation:
-
Select Web application as the application type
-
Add a name for your OAuth client
-
Under Authorized redirect URIs, add the following:
- https://<PATRONUS_APP_HOST>
- https://<PATRONUS_APP_HOST>/oauth2/auth
For example:
-
-
Click Create button.
-
After creation, you'll see your Client ID and Client Secret. Copy both values to a secure location.
Configuring the Helm chart
Once you have configured Google Identity OAuth, configure the values.yaml file with these values and apply the changes:
Configuring Admin Portal
Go to Admin Portal. In Accounts, create a new one with the following:
- Account Name:
<ACCOUNT_NAME> - Owner Email:
<YOUR_EMAIL> - Sign In Strategy:
Domain - Sign In Domain:
<YOUR_DOMAIN> - Limits Enabled:
disabled
Then go to System Authentication and add a mapping.
- Account:
<YOUR_NEWLY_CREATED_ACCOUNT> - Claim JSON-path:
$.aud - Match Claim Value:
<CLIENT_ID> - Grant Role:
Owner/Member
Change the Claim JSON-path and Match Claim Value to suit your needs.
External documentation:
- Google Kubernetes Engine (GKE)
- GKE Ingress for HTTP(S) Load Balancing
- Google Identity Platform
- Google OAuth 2.0 Documentation
- Vouch configuration example
