diff --git a/stable/nats/Chart.yaml b/stable/nats/Chart.yaml index 2310083c05..52e01c44b2 100644 --- a/stable/nats/Chart.yaml +++ b/stable/nats/Chart.yaml @@ -1,5 +1,5 @@ name: nats -version: 2.0.1 +version: 2.0.2 appVersion: 1.3.0 description: An open-source, cloud-native messaging system keywords: diff --git a/stable/nats/templates/_helpers.tpl b/stable/nats/templates/_helpers.tpl index ef93757d98..2609856746 100644 --- a/stable/nats/templates/_helpers.tpl +++ b/stable/nats/templates/_helpers.tpl @@ -69,5 +69,13 @@ Return the proper image name (for the metrics image) {{- $registryName := .Values.metrics.image.registry -}} {{- $repositoryName := .Values.metrics.image.repository -}} {{- $tag := .Values.metrics.image.tag | toString -}} -{{- printf "%s/%s:%s" $registryName $repositoryName $tag -}} +{{- if .Values.global }} + {{- if .Values.global.imageRegistry }} + {{- printf "%s/%s:%s" .Values.global.imageRegistry $repositoryName $tag -}} + {{- else -}} + {{- printf "%s/%s:%s" $registryName $repositoryName $tag -}} + {{- end -}} +{{- else -}} + {{- printf "%s/%s:%s" $registryName $repositoryName $tag -}} +{{- end -}} {{- end -}}