mirror of
https://github.com/goharbor/harbor
synced 2025-04-08 18:11:30 +00:00
32 lines
1003 B
Smarty
32 lines
1003 B
Smarty
{{/* vim: set filetype=mustache: */}}
|
|
{{/*
|
|
Expand the name of the chart.
|
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
|
*/}}
|
|
{{- define "harbor.name" -}}
|
|
{{- default "harbor" .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
|
{{- end -}}
|
|
|
|
{{/*
|
|
Create a default fully qualified app name.
|
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
|
*/}}
|
|
{{- define "harbor.fullname" -}}
|
|
{{- $name := default "harbor" .Values.nameOverride -}}
|
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
|
{{- end -}}
|
|
|
|
{{/* Helm required labels */}}
|
|
{{- define "helm.labels" -}}
|
|
heritage: {{ .Release.Service }}
|
|
release: {{ .Release.Name }}
|
|
chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
|
|
app: "{{ template "harbor.name" . }}"
|
|
{{- end -}}
|
|
|
|
{{/* matchLabels */}}
|
|
{{- define "helm.matchLabels" -}}
|
|
release: {{ .Release.Name }}
|
|
app: "{{ template "harbor.name" . }}"
|
|
{{- end -}}
|