Skip to content

Commit

Permalink
update logic
Browse files Browse the repository at this point in the history
  • Loading branch information
avimoondra committed Feb 6, 2024
1 parent 1f6b046 commit a330ab6
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions charts/retool/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ Usage: (include "retool.codeExecutor.enabled" .)
{{- else -}}
{{- $output = "" -}}
{{- end -}}
{{- else if empty (include "retool.codeExecutor.image.tag" .) -}}
{{- $output = "" -}}
{{- else if semverCompare ">= 3.20.15" (include "retool.codeExecutor.image.tag" .) -}}
{{- $output = "1" -}}
{{- else -}}
Expand Down Expand Up @@ -234,8 +236,10 @@ Usage: (template "retool.codeExecutor.image.tag" .)
{{- if .Values.codeExecutor.image.tag -}}
{{- .Values.codeExecutor.image.tag -}}
{{- else if .Values.image.tag -}}
{{- if eq .Values.image.tag "latest" -}}
{{- fail "If using image.tag=latest (not recommended), explicitly set codeExecutor.image.tag" }}
{{- if and (eq .Values.image.tag "latest") (eq (toString .Values.codeExecutor.enabled) "true") -}}
{{- fail "If using image.tag=latest (not recommended, select an explicit tag instead) and enabling codeExecutor, explicitly set codeExecutor.image.tag" }}
{{- else if (eq .Values.image.tag "latest") -}}
{{- "" -}}
{{- else if semverCompare ">= 3.20.15" .Values.image.tag -}}
{{- .Values.image.tag -}}
{{- else -}}
Expand All @@ -244,4 +248,4 @@ Usage: (template "retool.codeExecutor.image.tag" .)
{{- else -}}
{{- fail "Please set a value for .Values.image.tag" }}
{{- end -}}
{{- end -}}
{{- end -}}

0 comments on commit a330ab6

Please sign in to comment.