1 # Copyright © 2017 Amdocs, Bell Canada
2 # Modifications Copyright © 2020 AT&T
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
8 # http://www.apache.org/licenses/LICENSE-2.0
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.
19 name: {{ include "common.fullname" . }}
20 namespace: {{ include "common.namespace" . }}
22 app: {{ include "common.name" . }}
23 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
24 release: {{ include "common.release" . }}
25 heritage: {{ .Release.Service }}
29 app: {{ include "common.name" . }}
30 replicas: {{ .Values.replicaCount }}
34 app: {{ include "common.name" . }}
35 release: {{ include "common.release" . }}
38 - name: {{ include "common.name" . }}-job-completion
39 image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}"
40 imagePullPolicy: "{{ .Values.global.pullPolicy | default .Values.pullPolicy }}"
45 - {{ include "common.release" . }}-portal-db-config
51 fieldPath: metadata.namespace
52 - name: {{ include "common.name" . }}-portal-config
53 image: "{{ .Values.global.envsubstImage }}"
54 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
56 args: [ "-c", "cd /config-input && for PFILE in `ls -1 .`; do envsubst <${PFILE} >/config/${PFILE}; done"]
59 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "portal-cass" "key" "login") | indent 12 }}
60 - name: CASSA_PASSWORD
61 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "portal-cass" "key" "password") | indent 12 }}
62 - name: CIPHER_ENC_KEY
63 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "cipher-enc-key" "key" "password") | indent 12 }}
64 - name: PORTAL_DB_USER
65 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "portal-backend-db" "key" "login") | indent 12 }}
66 - name: PORTAL_DB_PASSWORD
67 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "portal-backend-db" "key" "password") | indent 12 }}
69 - mountPath: /config-input
70 name: properties-onapportal-scrubbed
72 name: properties-onapportal
73 {{ include "common.certInitializer.initContainer" . | indent 6 }}
75 - name: {{ include "common.name" . }}
76 image: "{{ include "common.repository" . }}/{{ .Values.image }}"
77 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
78 command: ["bash","-c"]
79 {{- if .Values.global.aafEnabled }}
80 args: ["export $(grep '^c' {{ .Values.certInitializer.credsPath }}/mycreds.prop | xargs -0);\
81 export _JAVA_OPTIONS=\"-Djavax.net.ssl.trustStorePassword=$cadi_truststore_password \
82 -Djavax.net.ssl.keyStorePassword=$cadi_keystore_password_p12\";\
83 /start-apache-tomcat.sh -i \"\" -n \"\" -b {{ .Values.global.env.tomcatDir }}"]
87 -Djavax.net.ssl.keyStore="{{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.keystoreFile }}"
88 -Djavax.net.ssl.trustStore="{{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.truststoreFile }}"
90 args: ["/start-apache-tomcat.sh -i "" -n "" -b {{ .Values.global.env.tomcatDir }}"]
93 - containerPort: {{ .Values.service.internalPort }}
94 - containerPort: {{ .Values.service.internalPort2 }}
95 - containerPort: {{ .Values.service.internalPort3 }}
96 - containerPort: {{ .Values.service.internalPort4 }}
97 {{- if eq .Values.liveness.enabled true }}
100 port: {{ .Values.service.internalPort }}
101 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
102 periodSeconds: {{ .Values.liveness.periodSeconds }}
106 port: {{ .Values.service.internalPort }}
107 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
108 periodSeconds: {{ .Values.readiness.periodSeconds }}
110 {{ include "common.certInitializer.volumeMount" . | indent 8 }}
111 - mountPath: /etc/localtime
114 - name: properties-onapportal
115 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/fusion/conf/fusion.properties"
116 subPath: fusion.properties
117 - name: properties-onapportal
118 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/classes/openid-connect.properties"
119 subPath: openid-connect.properties
120 - name: properties-onapportal
121 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/conf/system.properties"
122 subPath: system.properties
123 - name: properties-onapportal
124 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/classes/portal.properties"
125 subPath: portal.properties
126 - name: properties-onapportal
127 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/classes/key.properties"
128 subPath: key.properties
129 - name: properties-onapportal
130 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/classes/music.properties"
131 subPath: music.properties
132 - name: properties-onapportal
133 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/classes/logback.xml"
135 - name: properties-onapportal
136 mountPath: "{{ .Values.global.env.tomcatDir }}/conf/server.xml"
138 - name: properties-onapportal
139 mountPath: "{{ .Values.global.env.tomcatDir }}/webapps/ONAPPORTAL/WEB-INF/web.xml"
141 - name: properties-onapportal
142 mountPath: "{{ .Values.global.env.tomcatDir }}/temp"
144 mountPath: /var/log/onap
146 {{ include "common.resources" . }}
147 {{- if .Values.nodeSelector }}
149 {{ toYaml .Values.nodeSelector | indent 10 }}
151 {{- if .Values.affinity }}
153 {{ toYaml .Values.affinity | indent 10 }}
155 - name: filebeat-onap
156 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
157 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
159 - mountPath: /usr/share/filebeat/filebeat.yml
161 subPath: filebeat.yml
162 - name: portal-data-filebeat
163 mountPath: /usr/share/filebeat/data
165 mountPath: /var/log/onap
167 {{ include "common.certInitializer.volumes" . | indent 8 }}
171 - name: properties-onapportal
174 - name: properties-onapportal-scrubbed
176 name: {{ include "common.fullname" . }}-onapportal
178 - name: filebeat-conf
180 name: portal-filebeat
183 - name: portal-data-filebeat
185 - name: portal-tomcat-logs
188 - name: "{{ include "common.namespace" . }}-docker-registry-key"