Passbolt on GKE Autopilot
Passbolt (Community Edition) is a free, open-source, team-oriented password
manager with GPG-based encryption and per-user/group credential sharing —
AGPL-3.0 licensed, ~6k GitHub stars. It occupies a different niche from this
catalog's Vaultwarden module: Vaultwarden is a personal/Bitwarden-compatible
vault, while Passbolt is built around organization-wide GPG-encrypted credential
sharing between users and groups. This module deploys the official
passbolt/passbolt image on GKE Autopilot on top of the
App_GKE foundation, which provisions and manages the shared
Google Cloud and Kubernetes infrastructure.
This guide focuses on the cloud services Passbolt uses and how to explore and operate them from the Google Cloud Console and the command line. For the mechanics that are common to every GKE application — Workload Identity, ingress, autoscaling, CI/CD, Cloud Armor, IAP, Binary Authorization, VPC Service Controls, backups, and the deployment lifecycle — refer to the App_GKE foundation guide rather than repeating them here.
1. Overview
Passbolt runs as a single Apache/PHP pod on GKE Autopilot. The deployment wires together a focused set of Google Cloud services:
| Capability | Google Cloud service | Notes |
|---|---|---|
| Compute | GKE Autopilot | Apache/PHP pod, port 80, 1 vCPU / 2Gi by default, min_instance_count = 1, max_instance_count = 1 |
| Database | Cloud SQL for MySQL (MYSQL_8_0) | Required — Passbolt is a MySQL-only CakePHP application; discrete DATASOURCES_DEFAULT_* env vars, not a single DSN |
| Cryptographic state | Two dedicated GCS-Fuse volumes (storage, jwt) | Hold the vendor-self-generated GPG server keypair and JWT keypair — not Terraform-generated secrets |
| Secrets | Secret Manager | Only the database password is generated by the foundation — Passbolt itself contributes no secret at all (Passbolt_Common's secret_ids output is always empty) |
| Ingress | Cloud Load Balancing | External LoadBalancer Service by default, optional custom domain + managed certificate |
Sensible defaults worth knowing up front:
- MySQL is mandatory.
database_typeresolves toMYSQL_8_0(fixed byPassbolt_Common); Passbolt is built on CakePHP with a MySQL-only schema. - No server-side application secret. Unlike WordPress (multiple salts) or
Laravel-family apps (
APP_KEY), Passbolt has no Terraform-generated encryption key at all. Its security model is entirely client-side: the browser extension generates a GPG keypair and master password locally during setup. The server's own GPG keypair (for encrypting data to Passbolt) and its JWT keypair (API auth tokens) are both self-generated by the vendor's own entrypoint on first boot and persisted on dedicated GCS-Fuse volumes — not created or rotated by Terraform. - Two purpose-built GCS-Fuse volumes, not one, and not the whole
/etc/passboltdirectory.storagemounts narrowly at/etc/passbolt/gpg;jwtmounts narrowly at/etc/passbolt/jwt. Mounting a single volume over all of/etc/passboltwould shadow baked-in config/PHP files (app.php,bootstrap.php,routes.php) that live directly in that directory in the image — the same class of bug this catalog previously hit with Cloudreve. - GCS Fuse mount options set explicit
uid=33/gid=33— a real GKE-specific bug fix, not a defensive default. Even though thepassbolt/passboltimage's top-level container process runs as root, the vendor entrypoint'sgpg_gen_key()function actually performs the key-export step assu ... www-data(uid=33/gid=33). GKE's GCS Fuse CSI driver — unlike Cloud Run's own gcsfuse integration — does not default to a writable mount for a non-root UID, so both volumes explicitly setuid=33/gid=33(plusfile-mode=0664/dir-mode=0775) to avoidEACCESon first boot. This was found and fixed live: the same bug class as a uid-1000 Node app hit elsewhere in this catalog on the same day — always verify the actual runtime UID of whatever process writes to a GCS-Fuse-mounted path, not just the image's declaredUSER. HTTPS = "on"is always injected. Passbolt'sbootstrap.phphas$trustProxy = falsehardcoded, so it does not honorX-Forwarded-Protoby default — but it does check the literalenv('HTTPS')value directly. Since the GKE LoadBalancer terminates TLS at the edge and forwards plain HTTP to the pod, this static override makes Passbolt generatehttps://URLs correctly in emails and absolute links.enable_cloudsql_volumedefaults totruehere — matchingPassbolt_Common's own default, and the opposite ofPassbolt_CloudRun, whose top-level variable defaultsfalse.- No first-visit web setup wizard. The only way an admin account exists is
via the
admin-bootstrapinit job, which prints a one-time setup URL to its pod logs (surfaced in Cloud Logging) for the operator to open in a Passbolt-compatible browser extension. - No Redis.
enable_redis = falseby default — Passbolt has no Redis integration used by this module.
2. Google Cloud Services & How to Explore Them
All commands assume you have run
gcloud container clusters get-credentials <cluster> --region <region> --project <project>
and that PROJECT, REGION, and NAMESPACE are set. The namespace and other
identifiers are reported in the deployment Outputs.
A. GKE Autopilot — the Passbolt workload
- Console: Kubernetes Engine → Workloads → select the Passbolt workload to see pods, revisions, and events. Kubernetes Engine → Services & Ingress shows the external IP.
- CLI:
kubectl get pods,svc -n "$NAMESPACE"
kubectl logs -n "$NAMESPACE" deploy/<service-name> --tail=100
See App_GKE for how Autopilot and the workload type (Deployment vs StatefulSet) are managed.
B. Cloud SQL for MySQL
Passbolt stores all application data — users, groups, folders, encrypted
password resources, sharing permissions — in a managed Cloud SQL MySQL 8.0
instance. Pods reach it through the Cloud SQL Auth Proxy sidecar over a
loopback TCP connection (127.0.0.1) by default (enable_cloudsql_volume = true). The connection uses Passbolt's own discrete env var names
(DATASOURCES_DEFAULT_HOST/_USERNAME/_PASSWORD/_DATABASE, confirmed
against the vendor's own /passbolt/env.sh), aliased from the Foundation's
standard DB_* values by the Application Module.
- Console: SQL → select the instance for connections, backups, flags, and metrics.
- CLI:
gcloud sql instances list --project "$PROJECT"
gcloud sql instances describe <instance-name> --project "$PROJECT"
gcloud sql connect <instance-name> --user=<db-user> --database=<db-name> --project "$PROJECT"
See App_GKE for the connection model, automated backups, and password rotation.
C. Cloud Storage — the GPG and JWT keypair volumes
Two GCS buckets are provisioned by Passbolt_Common and mounted via the GCS
Fuse CSI driver: storage at /etc/passbolt/gpg, jwt at
/etc/passbolt/jwt, both with explicit uid=33/gid=33 mount options (see
Overview). These hold the vendor-self-generated server GPG keypair and JWT
keypair, both generated once on first boot and reused on every subsequent
boot. Losing either bucket invalidates every credential Passbolt has encrypted
server-side and every issued JWT session.
- Console: Cloud Storage → find the two buckets (names include
storageandjwtsuffixes). - CLI:
gsutil ls -p "$PROJECT" | grep passbolt
gsutil ls gs://<storage-bucket-name>/ # expect serverkey.asc, serverkey_private.asc
D. Secret Manager
Passbolt itself contributes no secret — the only Secret Manager entry related to this deployment is the database password, managed by the Foundation.
- Console: Security → Secret Manager.
- CLI:
gcloud secrets list --project "$PROJECT" --filter="name~passbolt"
E. Networking & ingress
By default the workload is exposed through an external Cloud Load Balancing IP
(service_type = LoadBalancer). A custom domain with a Google-managed
certificate can be enabled, and a static IP is reserved by default
(reserve_static_ip = true) so the address survives redeploys.
- Console: Network services → Load balancing; VPC network → IP addresses.
- CLI:
kubectl get svc -n "$NAMESPACE"
gcloud compute addresses list --project "$PROJECT"
See App_GKE for custom domains, Cloud CDN, and static IP details.
F. Cloud Logging & Monitoring
Pod stdout/stderr flow to Cloud Logging — including the admin-bootstrap init
job's one-time setup URL output. GKE and Cloud SQL metrics flow to Cloud
Monitoring, with optional uptime checks and alert policies.
- Console: Logging → Logs Explorer; Monitoring → Dashboards / Alerting.
- CLI:
gcloud logging read 'resource.type="k8s_container" AND resource.labels.namespace_name="'"$NAMESPACE"'"' \
--project "$PROJECT" --limit 50
3. Passbolt Application Behaviour
-
The 2-stage initialization job chain, and why the second job is genuinely non-trivial.
Passbolt_Commondefines two ordered Kubernetes Jobs, both withexecute_on_apply = true:-
db-init(mysql:8.0-debian) — creates the MySQL role and database (the shared catalog-widedb-init.sh,caching_sha2_password-safe). -
admin-bootstrap(passbolt/passbolt:<version>,depends_on_jobs = ["db-init"], mounts thestorageandjwtvolumes) — registers the initial admin account.Kubernetes Jobs invoke a container's
command/argsdirectly, bypassing the vendor's own/docker-entrypoint.shchain entirely — so a barecake passbolt register_useron a freshly-provisioned container fails with an Internal Error 500, because the GPG server keypair (normally generated during the vendor entrypoint's own boot sequence) doesn't exist yet, and the schema hasn't been installed either. The job instead sources the vendor's own entrypoint functions (/passbolt/entrypoint.sh,/passbolt/env.sh,/passbolt/deprecated_paths.sh), generates/imports the GPG server keypair if missing, generates a self-signed SSL cert if missing, runs the vendor's owninstall()function (which also handles JWT keypair generation and the database schema install/migrate), and only then runscake passbolt register_user -u <admin_email> -f <admin_first_name> -l <admin_last_name> -r admin— without the-q/quiet flag, so the one-time setup URL is printed and lands in the job pod's logs. Confirmed against the real vendor/passbolt/entrypoint.shsource. Idempotent:gpg_gen_key/install()no-op once the keys and schema already exist from a prior run.
On GKE,
execute_on_apply = false(if ever set on a custom job) would only stop Terraform from waiting for the job — the underlying Kubernetes Job/pod is still created and scheduled immediately either way. Correctness of thedb-init→admin-bootstrapordering here relies ondepends_on_jobs(App_GKE's job dependency system), not on apply-time sequencing. -
-
No first-visit setup wizard, and a genuinely different bootstrap model from most apps in this catalog. Passbolt requires the client (a browser extension) to generate its own GPG keypair and master password — there is no server-side password to seed and nothing to retrieve from Secret Manager. Retrieve the one-time setup URL instead:
kubectl get jobs -n "$NAMESPACE"
kubectl logs -n "$NAMESPACE" job/<admin-bootstrap-job-name> | grep '/setup/start/' -
Health endpoint.
GET /healthcheck/status.jsonreturns an unauthenticated200with{"header":{"status":"success",...},"body":"OK"}once ready — confirmed via local container testing and live deployment. Both the container-levelstartup_probe/liveness_probetarget this path by default. -
Inspect job execution:
kubectl get jobs -n "$NAMESPACE"
kubectl logs -n "$NAMESPACE" job/<job-name>
4. Configuration Variables
Variables are grouped exactly as they appear on the deployment platform. Only settings specific to or notable for Passbolt are listed; every other input is inherited from App_GKE with its standard behaviour and defaults.
Group 1 — Project & Identity
| Variable | Default | Description |
|---|---|---|
project_id | (required) | Target Google Cloud project. |
region | us-central1 | Region for the workload and regional resources. |
Group 2 — Deployment Environment
| Variable | Default | Description |
|---|---|---|
tenant_deployment_id | demo | Short suffix that makes resource names unique per environment. Use a distinct value (e.g. gke) from any co-deployed Passbolt_CloudRun (cr) to avoid a naming collision. |
support_users | [] | Emails granted project access and monitoring alerts. |
resource_labels | {} | Labels applied to all resources. |
Group 3 — Application & Database Identity
| Variable | Default | Description |
|---|---|---|
application_name | passbolt | Base name for resources. Do not change after first deploy. |
application_display_name | Passbolt | Human-readable name shown in the Console. |
application_version | latest | passbolt/passbolt image tag. |
admin_email | admin@example.com | Email for the admin account registered by admin-bootstrap. |
admin_first_name / admin_last_name | Admin / User | Name fields for the initial admin account. |
enable_gcs_storage_volume | true | Mounts the storage (GPG) and jwt GCS-Fuse volumes. Keep enabled. |
Group 4 — Runtime & Scaling
| Variable | Default | Description |
|---|---|---|
container_image_source | prebuilt | Deploys the official image directly; Passbolt only supports the prebuilt image. |
cpu_limit | 1000m | 1 vCPU. |
memory_limit | 2Gi | Memory limit — PHP 8.x + Apache. |
container_port | 80 | Passbolt (Apache) listens here. |
min_instance_count | 1 | Minimum pod replicas. |
max_instance_count | 1 | Maximum pod replicas. |
enable_cloudsql_volume | true | Cloud SQL Auth Proxy sidecar. Passbolt's DATASOURCES_DEFAULT_HOST alias resolves to the sidecar's loopback address when enabled. |
enable_image_mirroring | true | Mirrors the Passbolt image into Artifact Registry. |
Group 6 — GKE Backend Configuration
| Variable | Default | Description |
|---|---|---|
service_type | LoadBalancer | How the Kubernetes Service is exposed. |
workload_type | null (resolves to Deployment) | "Deployment" or "StatefulSet". |
session_affinity | ClientIP | Session affinity for the Kubernetes Service. |
namespace_name | "" (auto-generated) | Kubernetes namespace. |
Group 13 — NFS
| Variable | Default | Description |
|---|---|---|
enable_nfs | true | Provisions a Filestore volume. Not used by Passbolt's own persistence model — the GPG/JWT keypairs live on dedicated GCS-Fuse volumes and everything else is in MySQL. Harmless generic default. |
Group 14 — Cloud Storage
| Variable | Default | Description |
|---|---|---|
gcs_volumes | [] | Additional GCS buckets to mount via the GCS Fuse CSI driver, on top of the two Passbolt provisions automatically (storage, jwt). |
Group 16 — Database Configuration
| Variable | Default | Description |
|---|---|---|
database_type | null (resolves to MYSQL_8_0) | Cloud SQL engine. Passbolt requires MySQL. |
application_database_name | passbolt | MySQL database name. |
application_database_user | passbolt | MySQL application user. |
database_password_length | 32 | Generated password length (16–64). |
Group 11 — Workload Automation
| Variable | Default | Description |
|---|---|---|
initialization_jobs | [] | Leave empty for Passbolt_Common's default 2-job chain (db-init → admin-bootstrap). A non-empty list replaces it entirely. |
cron_jobs | [] | Passbolt has no platform-scheduled recurring tasks by default. |
Group 10 — Observability & Health
| Variable | Default | Description |
|---|---|---|
startup_probe / liveness_probe | HTTP /healthcheck/status.json | Container-level probes, passed through Passbolt_Common. |
startup_probe_config / health_check_config | Foundation LoadBalancer-level probes | Path "/" by default — distinct from the container-level probes above. |
uptime_check_config | { enabled=false, path="/" } | Cloud Monitoring uptime check. |
Group 15 — Redis
| Variable | Default | Description |
|---|---|---|
enable_redis | false | Not used by Passbolt. Present for platform compatibility. |
Group 19 — Custom Domain, Static IP & Networking
| Variable | Default | Description |
|---|---|---|
enable_custom_domain | true | Provision Ingress for custom hostnames. |
reserve_static_ip | true | Reserve a stable global static IP — recommended so the service address doesn't shift on redeploy. |
Every other input (Module Metadata, Environment Variables & Secrets, CI/CD &
GitHub Integration, Custom SQL, IAP & Cloud Armor, StatefulSet Configuration,
VPC Service Controls, Reliability Policies) is inherited from App_GKE with
its standard behaviour — see App_GKE for the full,
group-organized list.
5. Outputs
Returned on a successful deployment — the quickest way to locate and explore the running resources.
| Output | Description |
|---|---|
service_name | Kubernetes Service name. |
namespace | Namespace the workload runs in. |
service_cluster_ip / service_external_ip | In-cluster ClusterIP / external LoadBalancer IP. |
service_url | URL to reach Passbolt. |
database_instance_name | Cloud SQL instance name. |
database_name / database_user | Application database name / user. |
database_password_secret | Secret Manager secret holding the DB password. |
database_host / database_port | DB endpoint (127.0.0.1 via the Auth Proxy sidecar) / port. |
storage_buckets | The storage (GPG) and jwt GCS buckets. |
container_image | Deployed image. |
initialization_jobs | Names of the created init jobs (db-init, admin-bootstrap). |
kubernetes_ready | Whether the cluster endpoint is available and all workload resources are deployed. false on the first apply of a new inline cluster — a re-run completes the deployment. |
deployment_id / tenant_id / resource_prefix | Naming identifiers. |
project_id / project_number | Project identifiers. |
6. Configuration Pitfalls & Sensible Defaults
Risk: Critical (data loss / outage / security) — High (service degraded) — Medium (cost or partial degradation) — Low (minor).
Inherited plan-time validation. This module passes its configuration through the App_GKE foundation engine, which validates values and combinations at plan time. Invalid configuration fails the plan with a clear, named error before any resource is created.
| Setting | Sensible value | Risk | Consequence if wrong |
|---|---|---|---|
database_type | resolves to MYSQL_8_0 | Critical | Passbolt's CakePHP schema is MySQL-only — any other engine breaks startup entirely. |
enable_gcs_storage_volume | true | Critical | Disabling loses the persistent volumes for the self-generated GPG server keypair and JWT keypair — every credential Passbolt has encrypted server-side, and every issued JWT session, becomes unrecoverable on the next pod restart. |
GCS Fuse uid=33/gid=33 mount options | Already set in Passbolt_Common — do not remove if customizing gcs_volumes | Critical | Without them, www-data (the uid the vendor entrypoint's key-generation step actually runs as) gets EACCES: permission denied writing the GPG/JWT key files on first boot, and the pod never becomes genuinely usable even if it reports Ready. |
initialization_jobs order (db-init → admin-bootstrap) | Leave [] unless you fully understand the dependency | Critical | The admin-bootstrap job's replication of the vendor's own GPG-key-generation/schema-install sequence is load-bearing — a naive replacement job that just runs cake passbolt register_user directly fails with an Internal Error because the GPG server keypair and schema don't exist yet. On GKE, execute_on_apply=false does NOT delay pod scheduling — only Terraform's wait — so the ordering guarantee comes entirely from depends_on_jobs. |
enable_cloudsql_volume | true (this variant's default) | High | The Auth Proxy sidecar is the intended MySQL connectivity path on GKE. |
reserve_static_ip | true | Medium | Without a reserved static IP, the external LoadBalancer address can change across redeploys, breaking any bookmarked URL or DNS record pointed at it. |
admin_email / admin_first_name / admin_last_name | Set intentionally before first deploy | Medium | These seed the one and only admin account the admin-bootstrap job creates; there is no in-app way to change them after the fact except through Passbolt's own admin UI once logged in. |
| No admin password to lose track of | — | — | Unlike most apps in this catalog, there is no Secret-Manager-held admin credential to retrieve. If the one-time setup URL is missed and expires, the fix is re-running the admin-bootstrap job (idempotent for the GPG/JWT/schema steps; check Passbolt's own CLI docs for re-issuing a setup link for register_user). |
For the foundation behaviour referenced throughout — Workload Identity, autoscaling, ingress and certificates, CI/CD, Cloud Armor, IAP, Binary Authorization, VPC-SC, backups, and image mirroring — see App_GKE. Passbolt-specific application configuration shared with the Cloud Run variant is described in Passbolt_Common.