argocd-helm/charts/argo-rollouts/templates/controller/clusterrolebinding.yaml
jphelton b029a6dde3
feat(argo-rollouts): flag to disable clusterrole/clusterrolebinding creation (#1388)
* feat(argo-rollouts): Add flag to optionally disable the creation of cluster roles (even when running in cluster mode)

Signed-off-by: Joshua Helton <jdoghelton@gmail.com>

* fix README.md with helm-docs.sh

Signed-off-by: Joshua Helton <jdoghelton@gmail.com>

Signed-off-by: Joshua Helton <jdoghelton@gmail.com>
Co-authored-by: JM <jmeridth@gmail.com>
2022-08-22 21:43:13 -05:00

17 lines
590 B
YAML

{{- if and .Values.clusterInstall .Values.controller.createClusterRole }}
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: {{ include "argo-rollouts.fullname" . }}
labels:
app.kubernetes.io/component: {{ .Values.controller.component }}
{{- include "argo-rollouts.labels" . | nindent 4 }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ include "argo-rollouts.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ include "argo-rollouts.serviceAccountName" . }}
namespace: {{ .Release.Namespace }}
{{- end }}