1 # Copyright © 2017 Amdocs, AT&T, Bell Canada
2 # Modifications Copyright © 2018 ZTE
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.
16 apiVersion: extensions/v1beta1
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 }}
27 replicas: {{ .Values.replicaCount }}
31 app: {{ include "common.name" . }}
32 release: {{ include "common.release" . }}
35 - name: {{ include "common.name" . }}-readiness
46 fieldPath: metadata.namespace
47 image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
48 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
49 - name: {{ include "common.name" . }}-job-completion
50 image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
51 imagePullPolicy: "{{ .Values.global.pullPolicy | default .Values.pullPolicy }}"
53 - /root/job_complete.py
56 - {{ include "common.release" . }}-sdc-onboarding-be-cassandra-init
62 fieldPath: metadata.namespace
63 - name: {{ include "common.name" . }}-update-config
64 image: "{{ .Values.global.envsubstImage }}"
65 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
70 - "cd /config-input && for PFILE in `find . -not -type d | grep -v -F ..`; do envsubst <${PFILE} >/config-output/${PFILE}; chmod 0755 /config-output/${PFILE}; done"
75 name: {{ include "common.release" . }}-sdc-cs-secrets
76 key: keystore_password
77 - name: TRUSTSTORE_PASS
80 name: {{ include "common.release" . }}-sdc-cs-secrets
81 key: truststore_password
83 - name: {{ include "common.fullname" . }}-environments
84 mountPath: /config-input/
85 - name: sdc-environments-output
86 mountPath: /config-output/
88 - name: {{ include "common.name" . }}
89 image: "{{ include "common.repository" . }}/{{ .Values.image }}"
90 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
92 - containerPort: {{ .Values.service.internalPort }}
93 - containerPort: {{ .Values.service.internalPort2 }}
94 {{ if eq .Values.liveness.enabled true }}
97 path: /sdc2/rest/healthCheck
98 port: {{ .Values.service.internalPort }}
100 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
101 periodSeconds: {{ .Values.liveness.periodSeconds }}
102 timeoutSeconds: {{ .Values.liveness.timeoutSeconds }}
107 - "/var/lib/jetty/ready-probe.sh"
108 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
109 periodSeconds: {{ .Values.readiness.periodSeconds }}
110 timeoutSeconds: {{ .Values.readiness.timeoutSeconds }}
112 {{ include "common.resources" . | indent 12 }}
115 value: {{ .Values.global.env.name }}
117 value: {{ .Values.config.javaOptions }}
118 - name: cassandra_ssl_enabled
119 value: {{ .Values.config.cassandraSslEnabled | quote }}
123 fieldPath: status.podIP
125 - name: sdc-environments-output
126 mountPath: /var/lib/jetty/chef-solo/environments/
128 mountPath: /var/lib/jetty/chef-solo/cookbooks/sdc-catalog-be/files/default/org.onap.sdc.p12
129 subPath: org.onap.sdc.p12
131 mountPath: /var/lib/jetty/chef-solo/cookbooks/sdc-catalog-be/files/default/org.onap.sdc.trust.jks
132 subPath: org.onap.sdc.trust.jks
133 - name: {{ include "common.fullname" . }}-localtime
134 mountPath: /etc/localtime
136 - name: {{ include "common.fullname" . }}-logs
137 mountPath: /var/log/onap
138 - name: {{ include "common.fullname" . }}-logback
139 mountPath: /tmp/logback.xml
144 command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
145 # side car containers
146 - name: {{ include "common.name" . }}-filebeat-onap
147 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
148 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
150 - name: {{ include "common.fullname" . }}-filebeat-conf
151 mountPath: /usr/share/filebeat/filebeat.yml
152 subPath: filebeat.yml
153 - name: {{ include "common.fullname" . }}-logs
154 mountPath: /var/log/onap
155 - name: {{ include "common.fullname" . }}-data-filebeat
156 mountPath: /usr/share/filebeat/data
158 - name: {{ include "common.fullname" . }}-localtime
164 - name: {{ include "common.fullname" . }}-filebeat-conf
166 name: {{ include "common.release" . }}-sdc-filebeat-configmap
167 - name: {{ include "common.fullname" . }}-data-filebeat
169 - name: {{ include "common.fullname" . }}-logback
171 name : {{ include "common.fullname" . }}-logging-configmap
172 - name: {{ include "common.fullname" . }}-environments
174 name: {{ include "common.release" . }}-sdc-environments-configmap
176 - name: sdc-environments-output
177 emptyDir: { medium: "Memory" }
178 - name: {{ include "common.fullname" . }}-logs
181 - name: "{{ include "common.namespace" . }}-docker-registry-key"