Don't create ClusterRole if disabled

This commit is contained in:
Andrei Pohilko
2023-07-20 14:31:15 +01:00
parent 95f14ed295
commit 5b60263a41

View File

@@ -12,6 +12,7 @@ metadata:
{{- end }}
---
{{- if .Values.serviceAccount.create -}}
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
@@ -24,6 +25,7 @@ rules:
{{- else }}
verbs: ["get", "list", "watch"]
{{- end }}
{{- end }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding