Skip to content

Commit 8465333

Browse files
ngopalak-redhatk8s-ci-robot
authored andcommitted
Add webhook options only for openshift deployments to handle node debugging label
1 parent b6c28cb commit 8465333

File tree

4 files changed

+33
-1
lines changed

4 files changed

+33
-1
lines changed

deploy/openshift-dev.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2115,6 +2115,11 @@ spec:
21152115
description: Verbosity specifies the logging verbosity of the daemon.
21162116
type: integer
21172117
webhookOptions:
2118+
default:
2119+
- name: nodedebuggingpod.spo.io
2120+
objectSelector:
2121+
matchLabels:
2122+
debug.openshift.io/managed-by: oc-debug
21182123
description: |-
21192124
WebhookOpts set custom namespace selectors and failure mode for
21202125
SPO's webhooks

deploy/openshift-downstream.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1806,6 +1806,11 @@ spec:
18061806
description: Verbosity specifies the logging verbosity of the daemon.
18071807
type: integer
18081808
webhookOptions:
1809+
default:
1810+
- name: nodedebuggingpod.spo.io
1811+
objectSelector:
1812+
matchLabels:
1813+
debug.openshift.io/managed-by: oc-debug
18091814
description: |-
18101815
WebhookOpts set custom namespace selectors and failure mode for
18111816
SPO's webhooks

deploy/overlays/openshift-dev/kustomization.yaml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,22 @@ images:
1212
newTag: latest
1313
resources:
1414
- ../cluster
15-
1615
patches:
16+
- patch: |-
17+
- op: replace
18+
path: "/spec/versions/0/schema/openAPIV3Schema/properties/spec/properties/webhookOptions/default"
19+
value:
20+
- name: nodedebuggingpod.spo.io
21+
objectSelector:
22+
matchLabels:
23+
debug.openshift.io/managed-by: "oc-debug"
24+
target:
25+
kind: CustomResourceDefinition
26+
name: securityprofilesoperatordaemons.security-profiles-operator.x-k8s.io
1727
- patch: |-
1828
- op: add
1929
path: "/metadata/labels/openshift.io~1cluster-monitoring"
2030
value: "true"
2131
target:
2232
kind: Namespace
33+

deploy/overlays/openshift-downstream/kustomization.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,17 @@ sortOptions:
1010
resources:
1111
- ../cluster
1212
patches:
13+
- patch: |-
14+
- op: replace
15+
path: "/spec/versions/0/schema/openAPIV3Schema/properties/spec/properties/webhookOptions/default"
16+
value:
17+
- name: nodedebuggingpod.spo.io
18+
objectSelector:
19+
matchLabels:
20+
debug.openshift.io/managed-by: "oc-debug"
21+
target:
22+
kind: CustomResourceDefinition
23+
name: securityprofilesoperatordaemons.security-profiles-operator.x-k8s.io
1324
- path: service_discovery_rules.yaml
1425
target:
1526
kind: ClusterRole

0 commit comments

Comments
 (0)