First draft of the SMO package based on the ONAP charts
[it/dep.git] / smo-install / oran_oom / ric-common / templates / _namespace.tpl
1 ################################################################################
2 #   Copyright (c) 2019 AT&T Intellectual Property.                             #
3 #                                                                              #
4 #   Licensed under the Apache License, Version 2.0 (the "License");            #
5 #   you may not use this file except in compliance with the License.           #
6 #   You may obtain a copy of the License at                                    #
7 #                                                                              #
8 #       http://www.apache.org/licenses/LICENSE-2.0                             #
9 #                                                                              #
10 #   Unless required by applicable law or agreed to in writing, software        #
11 #   distributed under the License is distributed on an "AS IS" BASIS,          #
12 #   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   #
13 #   See the License for the specific language governing permissions and        #
14 #   limitations under the License.                                             #
15 ################################################################################
16
17 {{- define "common.namespace.platform" -}}
18   {{- $keylist := list "common" "namespace" "platform" -}}
19   {{- $ctx := dict "ctx" $.Values "keylist" $keylist -}}
20   {{- $namespace := include "locate" $ctx -}}
21   {{- if not (empty $namespace) -}}
22     {{- $namespace -}}
23   {{- else -}}
24     {{- printf "ricplt" -}}
25   {{- end -}}
26 {{- end -}}
27
28 {{- define "common.namespace.infra" -}}
29   {{- $keylist := list "common" "namespace" "infra" -}}
30   {{- $ctx := dict "ctx" $.Values "keylist" $keylist -}}
31   {{- $namespace := include "locate" $ctx -}}
32   {{- if not (empty $namespace) -}}
33     {{- $namespace -}}
34   {{- else -}}
35     {{- printf "ricinfra" -}}
36   {{- end -}}
37 {{- end -}}
38
39 {{- define "common.namespace.xapp" -}}
40   {{- $keylist := list "common" "namespace" "xapp" -}}
41   {{- $ctx := dict "ctx" $.Values "keylist" $keylist -}}
42   {{- $namespace := include "locate" $ctx -}}
43   {{- if not (empty $namespace) -}}
44     {{- $namespace -}}
45   {{- else -}}
46     {{- printf "ricxapp" -}}
47   {{- end -}}
48 {{- end -}}
49
50
51 {{- define "common.namespace.aux" -}}
52   {{- $keylist := list "common" "namespace" "aux" -}}
53   {{- $ctx := dict "ctx" $.Values "keylist" $keylist -}}
54   {{- $namespace := include "locate" $ctx -}}
55   {{- if not (empty $namespace) -}}
56     {{- $namespace -}}
57   {{- else -}}
58     {{- printf "ricaux" -}}
59   {{- end -}}
60 {{- end -}}