We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8dbde02 commit a78249cCopy full SHA for a78249c
charts/spark-connect/templates/role.yaml
@@ -1,4 +1,8 @@
1
-{{- if .Values.serviceAccount.create -}}
+{{- $shouldCreateServiceAccount := .Values.serviceAccount.create -}}
2
+{{- $resourceList := list "pods" "services" "configmaps" -}}
3
+{{- $verbList := list "*" -}}
4
+
5
+{{- if $shouldCreateServiceAccount }}
6
apiVersion: rbac.authorization.k8s.io/v1
7
kind: Role
8
metadata:
@@ -7,6 +11,6 @@ metadata:
11
{{- include "spark.labels" . | nindent 4 }}
12
rules:
9
13
- apiGroups: [""]
10
- resources: ["pods", "services", "configmaps"]
- verbs: ["*"]
14
+ resources: {{ toJson $resourceList }}
15
+ verbs: {{ toJson $verbList }}
16
{{- end }}
0 commit comments