Conversation
- Add vault.* section in values.yaml with enabled flag (false by default,
keeps backward compatibility with native Secret from values)
- Wrap postiz-secret.yaml in {{- if not .Values.vault.enabled }} so it is
not rendered when Vault flow is active
- Add postiz-secretstore.yaml: SecretStore vault-backend (kubernetes auth,
configurable server/mount/role)
- Add postiz-externalsecret.yaml: ExternalSecret for env vars (dataFrom
extract) and optional second ExternalSecret for psql-ca cert; target.name
matches the existing envFrom secretRef in Deployment so no Deployment
changes are needed for the basic case
- Add Reloader annotation secret.reloader.stakater.com/reload to
Deployment pod template (conditional on vault.enabled), listing all
Vault-backed Secrets so pods restart automatically on secret rotation
- Add optional psql-ca volume + volumeMount in Deployment
(vault.psqlCa.enabled)
- Switch bitnami dependency repositories to
oci://registry-1.docker.io/bitnamicharts
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (7)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
feat: add Vault + ESO secrets support with Reloader integration
Description
Implements the Vault → ENV в поде workflow described in
SECRETS_WF_REQUIREMENTS.md.When
vault.enabled: true, secrets are sourced from HashiCorp Vault KV v2 via External Secrets Operator: ESO authenticates to Vault using the pod's ServiceAccount JWT (kubernetes auth method), pulls all keys from the configured KV path and materialises them as a native KubernetesSecret. The Deployment picks up that Secret viaenvFrom. Stakater Reloader watches the Secret and automatically restarts the pod on rotation.When
vault.enabled: false(default), the chart behaves exactly as before — Secret is rendered fromvalues.yaml. No breaking changes.Type of change
How Has This Been Tested?
Deployed to a live Kubernetes 1.30 cluster with Vault (bank-vaults operator, KV v2), ESO and Stakater Reloader installed.
SecretStore vault-backend— statusValidExternalSecret— statusSecretSynced, KubernetesSecretcreated with all keys from Vault KV v2 pathsecret/b2b/<app>/backend/prod/envvault.enabled: falserenders native Secret from values as before, no regressionsTest Configuration:
Checklist
vault.enabled: falseby default)Additional Information
Does this change introduce any new Kubernetes resource types? Yes
SecretStore(external-secrets.io/v1),ExternalSecret(external-secrets.io/v1) — both rendered only whenvault.enabled: trueDoes this change modify any existing Kubernetes resource types? Yes
Deployment— added conditionalsecret.reloader.stakater.com/reloadannotation on pod template; optional psql-cavolume+volumeMount(vault.psqlCa.enabled)Secret— wrapped in{{- if not .Values.vault.enabled }}to avoid conflict with the ESO-owned Secret when Vault flow is activeAre there any changes to the values.yaml file? Yes
Added
vault.*block:Does this change require any specific Kubernetes permissions or RBAC changes? Yes
Cluster-side prerequisites (one-time, outside the chart):
kubernetes_hostanddisable_iss_validation: truevaultin namespacevaultmust haveClusterRoleBindingtosystem:auth-delegator— required for Vault to validate SA tokens viaTokenReviewAPIdefaultpolicy must retain capabilities forauth/token/lookup-self,auth/token/renew-self,auth/token/revoke-self,sys/capabilities-self— otherwise ESO gets 403 immediately after loginexternal-secretswithSecretStore/ExternalSecretCRDs availablesecret.reloader.stakater.com/reloadannotationPer-instance Vault configuration:
read-<app>withreadcapability onsecret/data/b2b/<app>/backend/prod/env<app>withbound_service_account_names: [<app>],bound_service_account_namespaces: [<app>],policies: [read-<app>],ttl: 1hsecret/b2b/<app>/backend/prod/env(KV v2)Are there any changes to chart dependencies? Yes
postgresqlandredisdependency repositories switched fromhttps://charts.bitnami.com/bitnamitooci://registry-1.docker.io/bitnamicharts— the current official Bitnami OCI registry. Chart versions unchanged.Have you updated the CHANGELOG.md file? No — no CHANGELOG exists in the repository.