29 lines
690 B
Smarty
29 lines
690 B
Smarty
{{/* vim: set filetype=mustache: */}}
|
|
|
|
{{/*
|
|
Create chart name and version as used by the chart label.
|
|
*/}}
|
|
{{- define "chart" -}}
|
|
{{- printf "%s-%s" $.Chart.Name $.Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
|
{{- end -}}
|
|
|
|
{{/*
|
|
Common labels
|
|
*/}}
|
|
{{- define "labels" -}}
|
|
helm.sh/chart: {{ include "chart" $ }}
|
|
{{ include "selectorLabels" $ }}
|
|
{{- if $.Chart.AppVersion }}
|
|
app.kubernetes.io/version: {{ $.Chart.AppVersion | quote }}
|
|
{{- end }}
|
|
app.kubernetes.io/managed-by: {{ $.Release.Service }}
|
|
{{- end -}}
|
|
|
|
{{/*
|
|
Selector labels
|
|
*/}}
|
|
{{- define "selectorLabels" -}}
|
|
app.kubernetes.io/name: {{ $.Chart.Name }}
|
|
app.kubernetes.io/instance: {{ $.Release.Name }}
|
|
{{- end -}}
|