Skip to content

Commit

Permalink
Set app version label from image tag first if present
Browse files Browse the repository at this point in the history
Signed-off-by: zeritti <[email protected]>
  • Loading branch information
zeritti committed Dec 26, 2024
1 parent 4694bd0 commit 04ea586
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions charts/prometheus-nginx-exporter/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ app.kubernetes.io/managed-by: {{ .Release.Service }}
app.kubernetes.io/component: metrics
app.kubernetes.io/part-of: {{ template "prometheus-nginx-exporter.name" . }}
{{- include "prometheus-nginx-exporter.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/version: {{ default .Chart.AppVersion .Values.image.tag | quote }}
{{- if .Values.additionalLabels }}
{{ toYaml .Values.additionalLabels }}
{{- end }}
Expand Down

0 comments on commit 04ea586

Please sign in to comment.