From 6cddb624aa7c7d05c5f644de1d4159dd41ffc704 Mon Sep 17 00:00:00 2001 From: mw Date: Fri, 13 Oct 2023 11:40:41 +0200 Subject: [PATCH] fix(base-cluster/kyverno): fix excluded namespaces --- charts/base-cluster/templates/kyverno/kyverno.yaml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/charts/base-cluster/templates/kyverno/kyverno.yaml b/charts/base-cluster/templates/kyverno/kyverno.yaml index 35ffb1980..879b6095c 100644 --- a/charts/base-cluster/templates/kyverno/kyverno.yaml +++ b/charts/base-cluster/templates/kyverno/kyverno.yaml @@ -83,10 +83,11 @@ spec: # This only works in clusters >=1.22 because it relies on the # kubernetes.io/metadata.name label on namespaces, which is active by # default since 1.22. - webhooks: - - namespaceSelector: - matchExpressions: - - key: kubernetes.io/metadata.name - operator: NotIn - values: {{- include "base-cluster.kyverno.ignoredNamespaces" . | nindent 18 }} + config: + webhooks: + - namespaceSelector: + matchExpressions: + - key: kubernetes.io/metadata.name + operator: NotIn + values: {{- include "base-cluster.kyverno.ignoredNamespaces" . | nindent 18 }} {{- end }}