External secret integration
External stores and consumption paths
External secret managers keep credentials in a dedicated system. Kubernetes integration can synchronize selected values into a Secret object or expose files via a CSI volume. Choose based on application requirements, threat model, reliability and operational ownership. Synchronization creates another copy to protect. Direct mounts can avoid a Kubernetes Secret copy if syncing is not enabled, but the application and node still handle sensitive data.
external store → operator → Kubernetes Secret → applicationexternal store → CSI provider/driver → mounted file → applicationExternal Secrets Operator reconciliation
External Secrets Operator is an optional controller with custom APIs. An ExternalSecret selects a store and remote fields and describes a target. This illustrative v1 object uses a namespaced SecretStore and periodic refresh. The fictional store is intentionally absent; no credentials or provider settings are supplied. CreatedOnce, Periodic and OnChange represent different refresh policies; check the deployed CRD and controller version. A successful synchronization does not prove a running process loaded the new credential.
apiVersion: external-secrets.io/v1kind: ExternalSecretmetadata: name: catalog-config namespace: book-identity-labspec: refreshPolicy: Periodic refreshInterval: 15m secretStoreRef: name: fictional-store kind: SecretStore target: name: catalog-credential creationPolicy: Owner data: - secretKey: credential remoteRef: key: fictional/catalog/credentialSecrets Store CSI Driver and rotation
Secrets Store CSI Driver is distinct from a normal persistent disk CSI driver use case. It mounts secret material through a provider and can optionally synchronize a Kubernetes Secret. Rotation must be supported and enabled for the installed driver and provider; current documentation describes it as an opt-in feature. File changes still require application reload; environment-variable consumption needs replacement. Do not assume a refresh interval is a guaranteed delivery deadline.
provider read → mount or sync → propagation → app reload → authentication checkcert-manager automates certificate requests
cert-manager is another independent add-on. A Certificate declares desired identity, issuer reference and target Secret. This fictional Issuer is missing by design. The sample requests a 90-day certificate and a 30-day renewal lead, and explicitly requests a new key on reissuance rather than relying on a version-dependent default. Actual duration depends on issuer behavior. Verify Certificate conditions, issuer readiness and application reload; the presence of a target Secret is not enough.
apiVersion: cert-manager.io/v1kind: Certificatemetadata: name: catalog-tls namespace: book-identity-labspec: secretName: catalog-tls dnsNames: - catalog.example.invalid issuerRef: name: fictional-issuer kind: Issuer group: cert-manager.io duration: 2160h renewBefore: 720h privateKey: rotationPolicy: AlwaysDesign for store and issuer outages
A temporary external store outage can prevent refresh or initial mount. An existing application may keep working with an old credential until expiry or revocation, depending on the integration and issuer. A new Pod may not start at all. Never assume stale data is acceptable; establish freshness limits, alert on errors and upcoming expiry, and test recovery. Limit store permissions and controller scope; a shared cluster-wide store may expand the trust boundary.
refresh failure + still-valid loaded credential → investigate and alertrefresh failure + expired credential → application unavailable or authentication failurePractice: compare evidence at each boundary
The lab includes a fictional ExternalSecret, Certificate and projected identity Pod plus version-only cases. Trace the external store revision, synchronized revision, loaded application revision and authentication result separately. Identify whether a missing store, delayed reconciliation or stale process explains the failure. For optional future testing, pin the add-on releases, verify CRDs and provider compatibility, use a disposable store and synthetic credentials, and plan backup, rotation and cleanup. No external service is contacted here.
lab-fixtures/secret-identity/README.mdCheck Your Understanding
Solidify your learning with the interactive assessment directly below this lesson.
Concept Quiz & Questions
External secret integration — knowledge check
Interpret synthetic credential and trust evidence.
What does an ExternalSecret describe?
Does syncing external data to a Kubernetes Secret remove the need for Secret protections?
Does a mounted file update guarantee application reload?
What does cert-manager Certificate issuerRef identify?
What evidence best confirms rotation succeeded?