Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use app version as default instead of latest #406

Merged
merged 1 commit into from
Jun 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 10 additions & 11 deletions charts/graphscope-store/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ app.kubernetes.io/instance: {{ .Release.Name }}
Return the proper graphscope-store image name
*/}}
{{- define "graphscope-store.image" -}}
{{ include "graphscope-store.images.image" .Values.image }}
{{ include "graphscope-store.images.image" . }}
{{- end -}}

{{/*
Expand Down Expand Up @@ -105,12 +105,6 @@ Return true if a configmap object should be created for graphscope-service
{{- end -}}
{{- end -}}

{{/*
Return the proper image name (for the init container volume-permissions image)
*/}}
{{- define "graphscope-store.volumePermissions.image" -}}
{{ include "graphscope-store.images.image" .Values.volumePermissions.image }}
{{- end -}}

{{/*
Renders a value that contains template.
Expand All @@ -128,16 +122,21 @@ Usage:

{{/*
Return the proper image name
{{ include "graphscope-store.images.image" .Values.path.to.the.image }}
{{ include "graphscope-store.images.image" . }}
*/}}
{{- define "graphscope-store.images.image" -}}
{{- $tag := .tag | toString -}}
{{- if .registry }}
{{- $tag := .Chart.AppVersion | toString -}}
{{- with .Values.image -}}
{{- if .tag -}}
{{- $tag = .tag | toString -}}
{{- end -}}
{{- if .registry -}}
{{- printf "%s/%s:%s" .registry .repository $tag -}}
{{- else -}}
{{- printf "%s:%s" .repository $tag -}}
{{- end -}}
{{- end -}}
{{- end -}}


{{/*
Expand Down Expand Up @@ -181,4 +180,4 @@ Get full broker list.
{{- $brokerList = append $brokerList (printf "%s-%d.%s-headless.%s.svc.%s:%d" $fullname $i $fullname $releaseNamespace $clusterDomain $servicePort) }}
{{- end }}
{{- join "," $brokerList | printf "%s" -}}
{{- end -}}
{{- end -}}
3 changes: 2 additions & 1 deletion charts/graphscope-store/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
image:
registry: registry.cn-hongkong.aliyuncs.com
repository: graphscope/graphscope-store
tag: latest
# Overrides the image tag whose default is the chart appVersion.
tag: ""
## Specify a imagePullPolicy
## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images
Expand Down
File renamed without changes.