Skip to main content
Learn how to deploy Infisical on Google Cloud Platform using Google Kubernetes Engine (GKE) for container orchestration. This guide covers setting up Infisical in a production-ready GCP environment using Cloud SQL (PostgreSQL) for the database, Memorystore (Redis) for caching, and Google Cloud Load Balancing for routing traffic.

Prerequisites

  • A Google Cloud Platform account with permissions to create VPCs, GKE clusters, Cloud SQL instances, Memorystore instances, and Load Balancers
  • Basic knowledge of GCP networking (VPC, subnets, firewall rules) and Kubernetes concepts
  • gcloud CLI installed and configured
  • kubectl installed for interacting with your GKE cluster
  • Helm installed (version 3.x) for deploying the Infisical Helm chart
  • An Infisical Docker image tag from Docker Hub
Do not use the latest tag in production. Always pin to a specific version to avoid unexpected changes during upgrades.

System Requirements

The following are minimum requirements for running Infisical on GCP GKE: For production deployments with many users or secrets, increase these values accordingly.

Deployment Steps

1

Set up network infrastructure (VPC, subnets, firewall rules)

Create a VPC network for hosting Infisical:VPC & Subnets:
  • Create a VPC-native network that will host your GKE cluster, Cloud SQL instance, and Memorystore instance
  • Create a subnet for your GKE cluster with an appropriate IP range
  • Define secondary IP ranges for Kubernetes pods and services:
    • Primary range: 10.0.0.0/20 (for nodes)
    • Secondary range for pods: 10.4.0.0/14
    • Secondary range for services: 10.8.0.0/20
Cloud Router & Cloud NAT:
  • Deploy a Cloud Router and NAT gateway for outbound internet access from private GKE nodes
Firewall Rules:
Enable Private Google Access:
Verify: Confirm your network infrastructure is created:
2

Provision Google Kubernetes Engine (GKE) cluster

Create a GKE cluster to host your Infisical deployment:
Connect to the cluster:
Verify: Confirm cluster is ready:
You should see your nodes listed and in a Ready state.
For private GKE clusters, you’ll need to access the cluster from within the VPC (via a bastion host or Cloud Shell) or configure authorized networks to allow your IP to access the control plane endpoint.
3

Provision Cloud SQL for PostgreSQL

Set up the PostgreSQL database for Infisical:
Create database and user:
Verify: Confirm Cloud SQL is ready:
Note the private IP address for your connection string:
4

Provision Memorystore for Redis

Set up Redis caching for Infisical:
Verify: Confirm Memorystore is ready:
Note the host IP for your connection string:
Memorystore for Redis does not support AUTH passwords. Security relies on VPC isolation and firewall rules. Ensure only your GKE cluster’s pods can access the Memorystore IP.
5

Securely store Infisical secrets and configuration

Generate and store the required secrets:Generate secrets:
Store your ENCRYPTION_KEY securely outside of GCP as well. Without this key, you cannot decrypt your secrets even if you restore the database.
Configure IAM for Secret Access (if using Secret Manager with Workload Identity):
6

Deploy Infisical using Helm

Deploy Infisical to your GKE cluster using the official Helm chart:Add the Infisical Helm Repository:
Create a Helm Values File:Create a file named infisical-values.yaml:
Reserve a Static IP Address:
Deploy Infisical:
Verify: Confirm deployment is successful:
Wait for all pods to be in Running state.
7

Configure HTTPS access with SSL/TLS

Secure your Infisical deployment with HTTPS:Force HTTPS Redirect:
Add the annotation to your ingress:
Verify: Test HTTPS access:
After completing the above steps, your Infisical instance should be up and running on GCP. You can now proceed with creating an admin account and configuring additional features.

Additional Configuration

Configure email sending for Infisical notifications and invitations:Using SendGrid:
Using Gmail:
Update your Helm values to include the SMTP secret:
Upgrade the deployment:
Verify: Check logs for SMTP configuration:
Access running containers for debugging:Exec into an Infisical pod:
Common debugging commands:
Run a debug pod:
Infisical automatically runs database migrations on startup. To manually manage migrations:Check migration status:
Run migrations manually:
Rollback migrations (if needed):
Always backup your database before running manual migrations. Use Cloud SQL automated backups or create a manual snapshot first.
Database Backups:Cloud SQL automated backups are enabled by default. To create a manual backup:
To restore from a backup:
Encryption Key Backup:The ENCRYPTION_KEY is critical. Store it securely:
  • In Google Secret Manager with restricted IAM permissions
  • In an offline encrypted backup in a secure physical location
  • Never store it in version control
Export secrets for backup:
Pre-upgrade checklist:
  1. Review Infisical release notes for breaking changes
  2. Backup your database
  3. Verify your ENCRYPTION_KEY is backed up
Upgrade process:
Rollback if needed:
Google Cloud Logging:View Infisical logs in Cloud Logging:
  • Navigate to Logging > Logs Explorer in the GCP Console
  • Filter: resource.type="k8s_container" resource.labels.namespace_name="infisical"
Set up Cloud Monitoring alerts:
Uptime checks:
  • Navigate to Monitoring > Uptime checks in the GCP Console
  • Create a check for https://infisical.example.com/api/status
  • Set check frequency (e.g., every 1 minute)
Enable OpenTelemetry:
Horizontal Pod Autoscaler:The HPA is configured in the Helm values. To verify:
GKE Cluster Autoscaler:Already enabled during cluster creation. To verify:
Adjust scaling parameters:
To completely remove Infisical and associated resources:Delete Helm release:
Delete GCP resources:
Deleting Cloud SQL will permanently delete all data. Ensure you have backups before proceeding.

Infrastructure as Code

A Terraform configuration for deploying Infisical infrastructure on GCP:
This is a simplified example to get you started. For a complete deployment, you’ll need to add Secret Manager resources, IAM bindings, and Kubernetes resources. Adapt this example to your infrastructure standards.

Troubleshooting

Symptoms: Pods stuck in Pending, CrashLoopBackOff, or Error state.Check pod status:
Common causes:
  • Insufficient resources: Check node capacity and resource requests
  • Image pull errors: Verify image tag and registry access
  • Secret not found: Ensure infisical-secrets exists in the namespace
  • Database connection failed: Verify Cloud SQL private IP and credentials
Symptoms: Database connection errors in logs.Verify connectivity:
Common causes:
  • VPC peering not established: Check private service connection
  • Firewall rules blocking traffic: Verify firewall allows port 5432
  • Wrong credentials: Verify username and password
  • Cloud SQL not in same VPC: Ensure private IP is configured
Symptoms: Redis connection errors in logs.Verify connectivity:
Common causes:
  • Memorystore not in same VPC: Verify network configuration
  • Firewall rules blocking traffic: Verify firewall allows port 6379
  • Wrong IP address: Verify the Memorystore host IP
Symptoms: Cannot access Infisical via the external URL.Check ingress status:
Common causes:
  • DNS not configured: Verify A record points to static IP
  • Certificate not ready: Check ManagedCertificate status
  • Backend unhealthy: Verify pods are passing health checks
  • Static IP not reserved: Ensure infisical-ip exists
Symptoms: ManagedCertificate stuck in Provisioning state.Check certificate status:
Common causes:
  • DNS not propagated: Wait for DNS propagation (can take up to 48 hours)
  • Domain verification failed: Ensure A record is correct
  • Rate limiting: Let’s Encrypt has rate limits for certificate issuance
  • Ingress not ready: Ensure ingress has an external IP assigned
Symptoms: Pods being OOMKilled or throttled.Check resource usage:
Solutions:
  • Increase resource limits in Helm values
  • Enable HPA for automatic scaling
  • Check for memory leaks in application logs
  • Review Cloud Monitoring dashboards for trends
Symptoms: Errors about decryption or invalid encryption key.Common causes:
  • Wrong ENCRYPTION_KEY: Verify the key matches what was used to encrypt data
  • Key not set: Ensure the secret contains ENCRYPTION_KEY
  • Key changed: The encryption key cannot be changed after initial setup
Verify key is set:
If you’ve lost your encryption key, encrypted data cannot be recovered. Always maintain secure backups of your encryption key.