{{"{{"}}/*
Expand the name of the chart.
*/{{"}}"}}
{{"{{"}}- define "{{ project_name }}.name" -{{"}}"}}
{{"{{"}}- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" {{"}}"}}
{{"{{"}}- end {{"}}"}}

{{"{{"}}/*
Create a default fully qualified app name.
*/{{"}}"}}
{{"{{"}}- define "{{ project_name }}.fullname" -{{"}}"}}
{{"{{"}}- if .Values.fullnameOverride {{"}}"}}
{{"{{"}}- .Values.fullnameOverride | trunc 63 | trimSuffix "-" {{"}}"}}
{{"{{"}}- else {{"}}"}}
{{"{{"}}- $name := default .Chart.Name .Values.nameOverride {{"}}"}}
{{"{{"}}- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" {{"}}"}}
{{"{{"}}- end {{"}}"}}
{{"{{"}}- end {{"}}"}}

{{"{{"}}/*
Common labels
*/{{"}}"}}
{{"{{"}}- define "{{ project_name }}.labels" -{{"}}"}}
helm.sh/chart: {{"{{"}}- include "{{ project_name }}.name" . {{"}}"}}
{{"{{"}}- include "{{ project_name }}.selectorLabels" . {{"}}"}}
app.kubernetes.io/managed-by: {{"{{" }} .Release.Service {{"}}"}}
{{"{{"}}- end {{"}}"}}

{{"{{"}}/*
Selector labels
*/{{"}}"}}
{{"{{"}}- define "{{ project_name }}.selectorLabels" -{{"}}"}}
app.kubernetes.io/name: {{"{{"}}- include "{{ project_name }}.name" . {{"}}"}}
app.kubernetes.io/instance: {{"{{" }} .Release.Name {{"}}"}}
{{"{{"}}- end {{"}}"}}
