feat(argo-workflows): Add helper function to determine image value, minus tag (#1754)
We have a situation where we want to exclude the registry so that images can be pulled from in-network mirrors. Currently when you exclude the registry, you get stuck with a prefixing forward slash. Had to keep the tags in the manifest files because helm template requires a colon in the image value. Otherwise I'd move it into the helper function. image entries changed: server, controller, executor Signed-off-by: jmeridth <jmeridth@gmail.com> Signed-off-by: jmeridth <jmeridth@gmail.com>pull/1597/head argo-workflows-0.22.8
parent
45861fadb7
commit
7992b5d04b
|
@ -3,7 +3,7 @@ appVersion: v3.4.4
|
|||
name: argo-workflows
|
||||
description: A Helm chart for Argo Workflows
|
||||
type: application
|
||||
version: 0.22.7
|
||||
version: 0.22.8
|
||||
icon: https://raw.githubusercontent.com/argoproj/argo-workflows/master/docs/assets/argo.png
|
||||
home: https://github.com/argoproj/argo-helm
|
||||
sources:
|
||||
|
@ -13,4 +13,4 @@ maintainers:
|
|||
url: https://argoproj.github.io/
|
||||
annotations:
|
||||
artifacthub.io/changes: |
|
||||
- "[Added]: Support podGCDeleteDelayDuration and podGCGracePeriodSeconds"
|
||||
- "[Added]: Helm helper function to allow image registry to be absent"
|
||||
|
|
|
@ -142,3 +142,14 @@ Return the default Argo Workflows app version
|
|||
{{- define "argo-workflows.defaultTag" -}}
|
||||
{{- default .Chart.AppVersion .Values.images.tag }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return full image name including or excluding registry based on existence
|
||||
*/}}
|
||||
{{- define "argo-workflows.image" -}}
|
||||
{{- if and .image.registry .image.repository -}}
|
||||
{{ .image.registry }}/{{ .image.repository }}
|
||||
{{- else -}}
|
||||
{{ .image.repository }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
|
|
@ -34,14 +34,14 @@ spec:
|
|||
{{- end }}
|
||||
containers:
|
||||
- name: controller
|
||||
image: "{{ .Values.controller.image.registry }}/{{ .Values.controller.image.repository }}:{{ default (include "argo-workflows.defaultTag" .) .Values.controller.image.tag }}"
|
||||
image: "{{- include "argo-workflows.image" (dict "context" . "image" .Values.controller.image) }}:{{ default (include "argo-workflows.defaultTag" .) .Values.controller.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.images.pullPolicy }}
|
||||
command: [ "workflow-controller" ]
|
||||
args:
|
||||
- "--configmap"
|
||||
- "{{ template "argo-workflows.controller.fullname" . }}-configmap"
|
||||
- "--executor-image"
|
||||
- "{{ .Values.executor.image.registry }}/{{ .Values.executor.image.repository }}:{{ default (include "argo-workflows.defaultTag" .) .Values.executor.image.tag }}"
|
||||
- "{{- include "argo-workflows.image" (dict "context" . "image" .Values.executor.image) }}:{{ default (include "argo-workflows.defaultTag" .) .Values.executor.image.tag }}"
|
||||
- "--loglevel"
|
||||
- "{{ .Values.controller.logging.level }}"
|
||||
- "--gloglevel"
|
||||
|
|
|
@ -35,7 +35,7 @@ spec:
|
|||
{{- end }}
|
||||
containers:
|
||||
- name: argo-server
|
||||
image: "{{ .Values.server.image.registry }}/{{ .Values.server.image.repository }}:{{ default (include "argo-workflows.defaultTag" .) .Values.server.image.tag }}"
|
||||
image: "{{- include "argo-workflows.image" (dict "context" . "image" .Values.server.image) }}:{{ default (include "argo-workflows.defaultTag" .) .Values.server.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.images.pullPolicy }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.server.securityContext | nindent 12 }}
|
||||
|
|
Loading…
Reference in New Issue