1 ################################################################################
2 # Copyright (c) 2019 AT&T Intellectual Property. #
3 # Copyright (c) 2019 Nokia. #
5 # Licensed under the Apache License, Version 2.0 (the "License"); #
6 # you may not use this file except in compliance with the License. #
7 # You may obtain a copy of the License at #
9 # http://www.apache.org/licenses/LICENSE-2.0 #
11 # Unless required by applicable law or agreed to in writing, software #
12 # distributed under the License is distributed on an "AS IS" BASIS, #
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
14 # See the License for the specific language governing permissions and #
15 # limitations under the License. #
16 ################################################################################
19 This is the root file that define the name of each component. Value here will be used to define other K8S resource name.
24 {{- define "common.name.appmgr" -}}
25 {{- if .Values.appmgr -}}
26 {{- if .Values.appmgr.nameOverride -}}
27 {{- printf "%s" .Values.appmgr.nameOverride -}}
29 {{- printf "appmgr" -}}
32 {{- printf "appmgr" -}}
36 {{- define "common.fullname.appmgr" -}}
37 {{- $name := ( include "common.name.appmgr" . ) -}}
38 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
42 {{- define "common.name.dbaas" -}}
43 {{- if .Values.dbaas -}}
44 {{- if .Values.dbaas.nameOverride -}}
45 {{- printf "%s" .Values.dbaas.nameOverride -}}
47 {{- printf "dbaas" -}}
50 {{- printf "dbaas" -}}
54 {{- define "common.fullname.dbaas" -}}
55 {{- $name := ( include "common.name.dbaas" . ) -}}
56 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
69 {{- define "common.name.e2mgr" -}}
70 {{- if .Values.e2mgr -}}
71 {{- if .Values.e2mgr.nameOverride -}}
72 {{- printf "%s" .Values.e2mgr.nameOverride -}}
74 {{- printf "e2mgr" -}}
77 {{- printf "e2mgr" -}}
82 {{- define "common.fullname.e2mgr" -}}
83 {{- $name := ( include "common.name.e2mgr" . ) -}}
84 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
87 {{- define "common.name.e2term" -}}
88 {{- if .Values.e2term -}}
89 {{- if .Values.e2term.nameOverride -}}
90 {{- printf "%s" .Values.e2term.nameOverride -}}
92 {{- printf "e2term" -}}
95 {{- printf "e2term" -}}
100 {{- define "common.fullname.e2term" -}}
101 {{- $name := ( include "common.name.e2term" . ) -}}
102 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
113 {{- define "common.name.rtmgr" -}}
114 {{- if .Values.rtmgr -}}
115 {{- if .Values.rtmgr.nameOverride -}}
116 {{- printf "%s" .Values.rtmgr.nameOverride -}}
118 {{- printf "rtmgr" -}}
121 {{- printf "rtmgr" -}}
126 {{- define "common.fullname.rtmgr" -}}
127 {{- $name := ( include "common.name.rtmgr" . ) -}}
128 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
136 {{- define "common.name.a1mediator" -}}
137 {{- if .Values.a1mediator -}}
138 {{- if .Values.a1mediator.nameOverride -}}
139 {{- printf "%s" .Values.a1mediator.nameOverride -}}
141 {{- printf "a1mediator" -}}
144 {{- printf "a1mediator" -}}
149 {{- define "common.fullname.a1mediator" -}}
150 {{- $name := ( include "common.name.a1mediator" . ) -}}
151 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
161 {{- define "common.name" -}}
162 {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
166 Create a default fully qualified application name.
167 Truncated at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
169 {{- define "common.fullname" -}}
170 {{- $name := default .Chart.Name .Values.nameOverride -}}
171 {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}