Skip to content

Commit 3784382

Browse files
authored
add webhook clusterrole/clusterrolebinding (#134)
1 parent 4e729ff commit 3784382

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

security/kubernetes-rbac/namespaced-rolebinding.yaml

+44
Original file line numberDiff line numberDiff line change
@@ -128,3 +128,47 @@ roleRef:
128128
kind: Role
129129
name: confluent-operator
130130
apiGroup: rbac.authorization.k8s.io
131+
---
132+
# required only when webhook is enabled
133+
apiVersion: rbac.authorization.k8s.io/v1
134+
kind: ClusterRole
135+
metadata:
136+
name: confluent-operator-webhook-operator
137+
rules:
138+
- apiGroups:
139+
- admissionregistration.k8s.io
140+
resources:
141+
- validatingwebhookconfigurations
142+
verbs:
143+
- get
144+
- update
145+
- apiGroups:
146+
- ""
147+
resources:
148+
- persistentvolumes
149+
verbs:
150+
- get
151+
- list
152+
- watch
153+
- apiGroups:
154+
- ""
155+
resources:
156+
- namespaces
157+
verbs:
158+
- get
159+
- list
160+
- watch
161+
---
162+
# required only when webhook is enabled
163+
apiVersion: rbac.authorization.k8s.io/v1
164+
kind: ClusterRoleBinding
165+
metadata:
166+
name: confluent-operator-webhook-operator
167+
subjects:
168+
- kind: ServiceAccount
169+
name: confluent-for-kubernetes # customize as required
170+
namespace: confluent # customize as required
171+
roleRef:
172+
kind: ClusterRole
173+
name: confluent-operator-webhook-operator
174+
apiGroup: rbac.authorization.k8s.io

0 commit comments

Comments
 (0)