feat: support acr controller in our chart
This commit is contained in:
parent
65ed48fb12
commit
1c4da57ab5
3 changed files with 35 additions and 42 deletions
|
@ -285,3 +285,20 @@ Helper template to set argocd server url in event reporter
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- printf "%s:%v" (include "argo-cd.server.fullname" .) $port }}
|
{{- printf "%s:%v" (include "argo-cd.server.fullname" .) $port }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create acr controller name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "argo-cd.acr-controller.fullname" -}}
|
||||||
|
{{- printf "%s-%s" (include "argo-cd.fullname" .) .Values.acrController.name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{/*
|
||||||
|
Create the name of the acr controller service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "argo-cd.acrControllerServiceAccountName" -}}
|
||||||
|
{{- if .Values.acrController.serviceAccount.create -}}
|
||||||
|
{{ default (include "argo-cd.event-reporter.fullname" .) .Values.acrController.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.acrController.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
|
@ -12,15 +12,15 @@ rules:
|
||||||
{{- toYaml .Values.acrController.clusterRoleRules.rules | nindent 2 }}
|
{{- toYaml .Values.acrController.clusterRoleRules.rules | nindent 2 }}
|
||||||
{{- else }}
|
{{- else }}
|
||||||
- apiGroups:
|
- apiGroups:
|
||||||
- '*'
|
- argoproj.io
|
||||||
resources:
|
resources:
|
||||||
- '*'
|
- applications
|
||||||
verbs:
|
verbs:
|
||||||
- '*'
|
- get
|
||||||
- nonResourceURLs:
|
- list
|
||||||
- '*'
|
- watch
|
||||||
verbs:
|
- patch
|
||||||
- '*'
|
- update
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -7,38 +7,14 @@ metadata:
|
||||||
labels:
|
labels:
|
||||||
{{- include "argo-cd.labels" (dict "context" . "component" .Values.acrController.name "name" .Values.acrController.name) | nindent 4 }}
|
{{- include "argo-cd.labels" (dict "context" . "component" .Values.acrController.name "name" .Values.acrController.name) | nindent 4 }}
|
||||||
rules:
|
rules:
|
||||||
- apiGroups:
|
- apiGroups:
|
||||||
- ""
|
- argoproj.io
|
||||||
resources:
|
resources:
|
||||||
- secrets
|
- applications
|
||||||
- configmaps
|
verbs:
|
||||||
verbs:
|
- get
|
||||||
- create
|
- list
|
||||||
- get
|
- watch
|
||||||
- list
|
- patch
|
||||||
- watch
|
- update
|
||||||
- update
|
|
||||||
- patch
|
|
||||||
- delete
|
|
||||||
- apiGroups:
|
|
||||||
- argoproj.io
|
|
||||||
resources:
|
|
||||||
- applications
|
|
||||||
- appprojects
|
|
||||||
- applicationsets
|
|
||||||
verbs:
|
|
||||||
- create
|
|
||||||
- get
|
|
||||||
- list
|
|
||||||
- watch
|
|
||||||
- update
|
|
||||||
- delete
|
|
||||||
- patch
|
|
||||||
- apiGroups:
|
|
||||||
- ""
|
|
||||||
resources:
|
|
||||||
- events
|
|
||||||
verbs:
|
|
||||||
- create
|
|
||||||
- list
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
Loading…
Reference in a new issue