Skip to content

Commit eb7a355

Browse files
committed
Exclude kube-system and kube-node-lease from webhook, explicity set matchPolicy to Equivalent
1 parent fd40b48 commit eb7a355

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

manifests/helm/templates/operator/webhook.yaml.tpl

+8
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@ webhooks:
1111
reinvocationPolicy: IfNeeded
1212
failurePolicy: Ignore
1313
timeoutSeconds: 2
14+
namespaceSelector:
15+
matchExpressions:
16+
- key: kubernetes.io/metadata.name
17+
operator: NotIn
18+
values:
19+
- kube-system
20+
- kube-node-lease
21+
matchPolicy: Equivalent
1422
rules:
1523
- apiGroups: [ "" ]
1624
apiVersions: [ "v1" ]

manifests/install/all/operator/base/webhook.yaml

+8
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,14 @@ webhooks:
1010
reinvocationPolicy: IfNeeded
1111
failurePolicy: Ignore
1212
timeoutSeconds: 2
13+
namespaceSelector:
14+
matchExpressions:
15+
- key: kubernetes.io/metadata.name
16+
operator: NotIn
17+
values:
18+
- kube-system
19+
- kube-node-lease
20+
matchPolicy: Equivalent
1321
rules:
1422
- apiGroups: [ "" ]
1523
apiVersions: [ "v1" ]

0 commit comments

Comments
 (0)