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 {{- $namespace := ( include "common.namespace.platform" . ) -}}
39 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
43 {{- define "common.name.dbaas" -}}
44 {{- if .Values.dbaas -}}
45 {{- if .Values.dbaas.nameOverride -}}
46 {{- printf "%s" .Values.dbaas.nameOverride -}}
48 {{- printf "dbaas" -}}
51 {{- printf "dbaas" -}}
55 {{- define "common.fullname.dbaas" -}}
56 {{- $name := ( include "common.name.dbaas" . ) -}}
57 {{- $namespace := ( include "common.namespace.platform" . ) -}}
58 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
71 {{- define "common.name.e2mgr" -}}
72 {{- if .Values.e2mgr -}}
73 {{- if .Values.e2mgr.nameOverride -}}
74 {{- printf "%s" .Values.e2mgr.nameOverride -}}
76 {{- printf "e2mgr" -}}
79 {{- printf "e2mgr" -}}
84 {{- define "common.fullname.e2mgr" -}}
85 {{- $name := ( include "common.name.e2mgr" . ) -}}
86 {{- $namespace := ( include "common.namespace.platform" . ) -}}
87 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
90 {{- define "common.name.e2term" -}}
91 {{- if .Values.e2term -}}
92 {{- if .Values.e2term.nameOverride -}}
93 {{- printf "%s" .Values.e2term.nameOverride -}}
95 {{- printf "e2term" -}}
98 {{- printf "e2term" -}}
103 {{- define "common.fullname.e2term" -}}
104 {{- $name := ( include "common.name.e2term" . ) -}}
105 {{- $namespace := ( include "common.namespace.platform" . ) -}}
106 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
117 {{- define "common.name.rtmgr" -}}
118 {{- if .Values.rtmgr -}}
119 {{- if .Values.rtmgr.nameOverride -}}
120 {{- printf "%s" .Values.rtmgr.nameOverride -}}
122 {{- printf "rtmgr" -}}
125 {{- printf "rtmgr" -}}
130 {{- define "common.fullname.rtmgr" -}}
131 {{- $name := ( include "common.name.rtmgr" . ) -}}
132 {{- $namespace := ( include "common.namespace.platform" . ) -}}
133 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
141 {{- define "common.name.submgr" -}}
142 {{- if .Values.submgr -}}
143 {{- if .Values.submgr.nameOverride -}}
144 {{- printf "%s" .Values.submgr.nameOverride -}}
146 {{- printf "submgr" -}}
149 {{- printf "submgr" -}}
154 {{- define "common.fullname.submgr" -}}
155 {{- $name := ( include "common.name.submgr" . ) -}}
156 {{- $namespace := ( include "common.namespace.platform" . ) -}}
157 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
165 {{- define "common.name.a1mediator" -}}
166 {{- if .Values.a1mediator -}}
167 {{- if .Values.a1mediator.nameOverride -}}
168 {{- printf "%s" .Values.a1mediator.nameOverride -}}
170 {{- printf "a1mediator" -}}
173 {{- printf "a1mediator" -}}
178 {{- define "common.fullname.a1mediator" -}}
179 {{- $name := ( include "common.name.a1mediator" . ) -}}
180 {{- $namespace := ( include "common.namespace.platform" . ) -}}
181 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
186 {{- define "common.name.nexus" -}}
187 {{- if .Values.nexus -}}
188 {{- if .Values.nexus.nameOverride -}}
189 {{- printf "%s" .Values.nexus.nameOverride -}}
191 {{- printf "nexus" -}}
194 {{- printf "nexus" -}}
199 {{- define "common.fullname.nexus" -}}
200 {{- $name := ( include "common.name.nexus" . ) -}}
201 {{- $namespace := ( include "common.namespace.infra" . ) -}}
202 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
205 {{- define "common.name.chartmuseum" -}}
206 {{- if .Values.chartmuseum -}}
207 {{- if .Values.chartmuseum.nameOverride -}}
208 {{- printf "%s" .Values.chartmuseum.nameOverride -}}
210 {{- printf "chartmuseum" -}}
213 {{- printf "chartmuseum" -}}
218 {{- define "common.fullname.chartmuseum" -}}
219 {{- $name := ( include "common.name.chartmuseum" . ) -}}
220 {{- $namespace := ( include "common.namespace.infra" . ) -}}
221 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
224 {{- define "common.name.dashboard" -}}
225 {{- if .Values.dashboard -}}
226 {{- if .Values.dashboard.nameOverride -}}
227 {{- printf "%s" .Values.dashboard.nameOverride -}}
229 {{- printf "dashboard" -}}
232 {{- printf "dashboard" -}}
237 {{- define "common.fullname.dashboard" -}}
238 {{- $name := ( include "common.name.dashboard" . ) -}}
239 {{- $namespace := ( include "common.namespace.aux" . ) -}}
240 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
243 {{- define "common.name.messagerouter" -}}
244 {{- if .Values.messagerouter -}}
245 {{- if .Values.messagerouter.nameOverride -}}
246 {{- printf "%s" .Values.messagerouter.nameOverride -}}
248 {{- printf "messagerouter" -}}
251 {{- printf "messagerouter" -}}
256 {{- define "common.fullname.messagerouter" -}}
257 {{- $name := ( include "common.name.messagerouter" . ) -}}
258 {{- $namespace := ( include "common.namespace.aux" . ) -}}
259 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
263 {{- define "common.name.ves" -}}
264 {{- if .Values.ves -}}
265 {{- if .Values.ves.nameOverride -}}
266 {{- printf "%s" .Values.ves.nameOverride -}}
276 {{- define "common.fullname.ves" -}}
277 {{- $name := ( include "common.name.ves" . ) -}}
278 {{- $namespace := ( include "common.namespace.aux" . ) -}}
279 {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}}
282 {{- define "common.name" -}}
283 {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
287 Create a default fully qualified application name.
288 Truncated at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
290 {{- define "common.fullname" -}}
291 {{- $name := default .Chart.Name .Values.nameOverride -}}
292 {{- printf "%s-%s" .Release.Namespace $name | trunc 63 | trimSuffix "-" -}}