Skip to content

Commit 65f0915

Browse files
JAORMXclaude
andcommitted
Remove Helm conditionals from generated ClusterRole
The ClusterRole is generated by controller-gen and CI verifies it matches. Helm conditionals cannot be used in generated files. The operator code guards are the enforcement mechanism — the ClusterRole permissions are a ceiling, not a guarantee. The registry-api ClusterRole/ClusterRoleBinding (hand-managed) retain their conditionals. Co-Authored-By: Claude Opus 4.6 <[email protected]>
1 parent 45382c3 commit 65f0915

File tree

1 file changed

+1
-16
lines changed
  • deploy/charts/operator/templates/clusterrole

1 file changed

+1
-16
lines changed

deploy/charts/operator/templates/clusterrole/role.yaml

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ rules:
1010
- configmaps
1111
- persistentvolumeclaims
1212
- secrets
13+
- serviceaccounts
1314
- services
1415
verbs:
1516
- create
@@ -19,20 +20,6 @@ rules:
1920
- patch
2021
- update
2122
- watch
22-
- apiGroups:
23-
- ""
24-
resources:
25-
- serviceaccounts
26-
verbs:
27-
- get
28-
- list
29-
- watch
30-
{{- if not .Values.operator.rbac.disableWorkloadRBAC }}
31-
- create
32-
- delete
33-
- patch
34-
- update
35-
{{- end }}
3623
- apiGroups:
3724
- ""
3825
resources:
@@ -95,7 +82,6 @@ rules:
9582
- get
9683
- list
9784
- watch
98-
{{- if not .Values.operator.rbac.disableWorkloadRBAC }}
9985
- apiGroups:
10086
- rbac.authorization.k8s.io
10187
resources:
@@ -109,7 +95,6 @@ rules:
10995
- patch
11096
- update
11197
- watch
112-
{{- end }}
11398
- apiGroups:
11499
- toolhive.stacklok.dev
115100
resources:

0 commit comments

Comments
 (0)