Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Fix Helm chart webhook exempt Namespace label templating #2090

Conversation

dippynark
Copy link
Contributor

What this PR does / why we need it:

Exempt Namespace label templating in the Helm chart uses a value field instead of values: kubectl explain validatingwebhookconfiguration.webhooks.namespaceSelector.matchExpressions

This PR fixes the templating to allow for a values override like this:

validatingWebhookExemptNamespacesLabels:
  kubernetes.io/metadata.name:
  - kube-system
  - gatekeeper-system
mutatingWebhookExemptNamespacesLabels:
  kubernetes.io/metadata.name:
  - kube-system
  - gatekeeper-system

Signed-off-by: Luke Addison <lukeaddison785@gmail.com>
@dippynark dippynark force-pushed the fix-exempt-namespace-label-templating branch from ab43b35 to 274d43d Compare June 5, 2022 00:27
@dippynark dippynark changed the title fix: Fix exempt Namespace label templating fix: Fix Helm chart webhook exempt Namespace label templating Jun 5, 2022
@chewong chewong requested a review from a team June 6, 2022 20:11
Copy link
Contributor

@maxsmythe maxsmythe left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@ritazh ritazh left a comment

Choose a reason for hiding this comment

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

LGTM

@ritazh ritazh merged commit 0e90af5 into open-policy-agent:master Jun 7, 2022
davis-haba pushed a commit to davis-haba/gatekeeper that referenced this pull request Jul 19, 2022
…olicy-agent#2090)

Fix exempt Namespace label templating

Signed-off-by: Luke Addison <lukeaddison785@gmail.com>
Signed-off-by: davis-haba <davishaba@google.com>
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.

4 participants