Skip to content

Commit b8913df

Browse files
authored
Update _helpers.tpl
Enable nameOverride for the default-backend
1 parent abc72db commit b8913df

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

bitnami/nginx-ingress-controller/templates/_helpers.tpl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,17 @@ Create a default fully qualified default backend name.
4343
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
4444
*/}}
4545
{{- define "nginx-ingress.defaultBackend.fullname" -}}
46+
{{- if .Values.fullnameOverride -}}
47+
{{- printf "%s-%s" .Values.fullnameOverride .Values.defaultBackend.name | trunc 63 | trimSuffix "-" -}}
48+
{{- else -}}
4649
{{- $name := default .Chart.Name .Values.nameOverride -}}
4750
{{- if contains $name .Release.Name -}}
4851
{{- printf "%s-%s" .Release.Name .Values.defaultBackend.name | trunc 63 | trimSuffix "-" -}}
4952
{{- else -}}
5053
{{- printf "%s-%s-%s" .Release.Name $name .Values.defaultBackend.name | trunc 63 | trimSuffix "-" -}}
5154
{{- end -}}
5255
{{- end -}}
56+
{{- end -}}
5357

5458
{{/*
5559
Create the name of the service account to use

0 commit comments

Comments
 (0)