How do you make pods pick up a rotated secret?
IntermediateConceptSecrets in GitOps
Answer
Environment variables are read only at container start, and mounted Secret files update eventually (not with subPath). Options: a checksum annotation on the pod template that changes when the secret changes (works when the secret is rendered from Git), Stakater Reloader watching Secrets and restarting workloads, or apps that re-read mounted files. ESO-managed values that change outside Git need Reloader or app-side reloading, because nothing in Git changes.
More on Secrets in GitOps
Why are plain Kubernetes Secrets a problem in GitOps?BeginnerHow does Sealed Secrets work?BeginnerWhat are Sealed Secrets scopes?IntermediateHow does Sealed Secrets key rotation work, and what must you back up?AdvancedHow does External Secrets Operator fit into GitOps?BeginnerShow an ExternalSecret for AWS Secrets Manager.Intermediate