Skip to content

Commit 9b46b57

Browse files
committed
fix: CRD permissions
- Add missing description - Remove `get`, it is never used - Make list/watch unconditional
1 parent 9a4f426 commit 9b46b57

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

deploy/helm/druid-operator/templates/roles.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,21 +94,22 @@ rules:
9494
- get
9595
- list
9696
- patch
97+
# Required for maintaining the CRDs within the operator (including the conversion webhook info).
98+
# Also for the startup condition check before the controller can run.
9799
- apiGroups:
98100
- apiextensions.k8s.io
99101
resources:
100102
- customresourcedefinitions
101103
verbs:
102-
- get
103104
# Required to maintain the CRD. The operator needs to do this, as it needs to enter e.g. it's
104105
# generated certificate in the conversion webhook.
105106
{{- if .Values.maintenance.customResourceDefinitions.maintain }}
106107
- create
107108
- patch
109+
{{- end }}
108110
# Required for startup condition
109111
- list
110112
- watch
111-
{{- end }}
112113
# Listener created per role group for external access. Applied via SSA and tracked for orphan
113114
# cleanup. Not watched by the controller (no .owns() or .watches() on Listener in main.rs).
114115
- apiGroups:

0 commit comments

Comments
 (0)