diff --git a/charts/argo-cd/templates/argocd-configs/argocd-rbac-cm.yaml b/charts/argo-cd/templates/argocd-configs/argocd-rbac-cm.yaml index 8bbb7a93..8f00a09a 100644 --- a/charts/argo-cd/templates/argocd-configs/argocd-rbac-cm.yaml +++ b/charts/argo-cd/templates/argocd-configs/argocd-rbac-cm.yaml @@ -1,7 +1,8 @@ +{{- if .Values.server.rbacConfigMapEnabled }} apiVersion: v1 kind: ConfigMap metadata: - name: argocd-rbac-cm + name: {{ .Values.server.rbacConfigMapName }} labels: app.kubernetes.io/name: {{ include "argo-cd.name" . }}-rbac-cm helm.sh/chart: {{ include "argo-cd.chart" . }} @@ -18,4 +19,5 @@ metadata: {{- if .Values.server.rbacConfig }} data: {{- toYaml .Values.server.rbacConfig | nindent 4 }} +{{- end }} {{- end }} \ No newline at end of file diff --git a/charts/argo-cd/values.yaml b/charts/argo-cd/values.yaml index 7e8d00f3..c39d9484 100755 --- a/charts/argo-cd/values.yaml +++ b/charts/argo-cd/values.yaml @@ -595,6 +595,14 @@ server: ## Annotations to be added to ArgoCD rbac ConfigMap rbacConfigAnnotations: {} + # Name of the configmap used for the RBAC config. Must be set to `argocd-rbac-cm` as the values are hardcoded in + # ArgoCD. See https://github.com/argoproj/argo-cd/blob/master/common/common.go + rbacConfigMapName: "argocd-rbac-cm" + + # Boolean determining whether or not to create the configmap. If false, it is expected tthe configmap will be created + # by something else. ArgoCD will not work if there is no configMap created with the name above. + rbacConfigMapEnabled: true + ## Not well tested and not well supported on release v1.0.0. ## Applications ## reference: https://github.com/argoproj/argo-cd/blob/master/docs/operator-manual/