Skip to content

feat: add one-shot provisioning for keycloak-users ExternalSecret#14

Open
minmzzhang wants to merge 1 commit into
validatedpatterns:mainfrom
minmzzhang:one-shot-keycloak-users
Open

feat: add one-shot provisioning for keycloak-users ExternalSecret#14
minmzzhang wants to merge 1 commit into
validatedpatterns:mainfrom
minmzzhang:one-shot-keycloak-users

Conversation

@minmzzhang
Copy link
Copy Markdown
Contributor

@minmzzhang minmzzhang commented May 21, 2026

When externalSecrets.oneShot is true, the keycloak-users ExternalSecret becomes an ArgoCD Sync hook with BeforeHookCreation and deletionPolicy: Retain. This allows a PostSync job in the rh-keycloak wrapper chart (layered-zero-trust) to delete the ExternalSecret with --cascade=orphan so the Secret survives initial provisioning, then clean up ephemeral Secrets labeled for deletion.

Defaults to false (oneShot disabled) — keycloak-users is a regular ExternalSecret with no hook annotations. The Secret and ExternalSecret simply persist. The rh-keycloak wrapper chart in layered-zero-trust enables it via rhbk.externalSecrets.oneShot.

Bump chart version to 0.0.9.

Comment thread templates/keycloak-users-external-secret.yaml Outdated
When externalSecrets.oneShot is true, the keycloak-users
ExternalSecret becomes an ArgoCD Sync hook with BeforeHookCreation
and deletionPolicy: Retain. This allows a PostSync job in the
rh-keycloak wrapper chart (layered-zero-trust) to delete the
ExternalSecret with --cascade=orphan so the Secret survives
initial provisioning, then clean up ephemeral Secrets labeled
for deletion.

Defaults to false (oneShot disabled) — keycloak-users is a regular
ExternalSecret with no hook annotations. The Secret and
ExternalSecret simply persist. The rh-keycloak wrapper chart in
layered-zero-trust enables it via rhbk.externalSecrets.oneShot.

Also fixes NATURAL_LANGUAGE linter errors: postgresql -> PostgreSQL
in values.yaml comments and README.md.gotmpl.

Bump chart version to 0.0.9.

Signed-off-by: Min Zhang <minzhang@redhat.com>
@minmzzhang minmzzhang force-pushed the one-shot-keycloak-users branch from 3c201dd to 0f3c0a3 Compare May 22, 2026 02:13
Copy link
Copy Markdown
Contributor

@sabre1041 sabre1041 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this implementation will retain the prior default configuration.

Additional work will be needed to attempt to handle the orphan/deletion use case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants