-
Notifications
You must be signed in to change notification settings - Fork 7
Description
Problem
When tls_disable: true is set in the Vault listener config, the chart still unconditionally:
- Mounts a
vault-tlsSecret at/vault/tlson all containers (vault, vault-unsealer, vault-configurer) - Sets
VAULT_CACERT=/vault/tls/ca.crton all containers - Generates random TLS certificates via
genCA/genSignedCert(unlesstls.secretNameor cert-manager is configured)
There is no way to disable this behavior. The chart acknowledges tls_disable for HTTP/HTTPS probe scheme selection in statefulset.yaml, but doesn't carry that logic through to the volume mount, env var, or cert generation.
Impact
- ArgoCD drift:
genCA/genSignedCertproduce new random certs on everyhelm templaterender. This causes perpetual OutOfSync on both thevault-tlsSecret and the StatefulSet (via itschecksum/configannotation, which hashes the entiresecret.yamloutput including cert data). This is a well-known Helm + ArgoCD issue. - Unnecessary resources: When TLS is disabled, the cert Secret, volume mount, and env var serve no purpose.
Current workaround
Set tls.secretName: "vault-tls" to skip cert generation, then provide a static Secret with dummy cert data to satisfy the unconditional volume mount. This works but requires maintaining an otherwise pointless Secret manifest.
Proposed solution
Add a tls.enabled toggle (defaulting to true for backward compatibility) that wraps:
- The cert generation block in
secret.yaml(line 1) - The
vault-tlsvolume definition instatefulset.yaml(~line 312) - The
vault-tlsvolumeMount in all three containers - The
VAULT_CACERTenv var in all three containers
Alternatively, the chart could read vault.config.listener.tcp.tls_disable (which it already references for probe schemes) and skip TLS provisioning when it's true.
Affected templates
vault/templates/secret.yaml— lines 1-26 (cert generation)vault/templates/statefulset.yaml— lines 84-85, 150-151, 165-166, 192-193, 207-208, 232-233 (VAULT_CACERT + volumeMount), lines 312-320 (volume definition)
Environment
- Chart version: v1.21.1
- Vault image: hashicorp/vault:1.17.6
- GitOps tool: ArgoCD