1 # Copyright © 2017 Amdocs, Bell Canada
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 apiVersion: extensions/v1beta1
18 name: {{ include "common.fullname" . }}
19 namespace: {{ include "common.namespace" . }}
21 app: {{ include "common.name" . }}
22 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
23 release: {{ .Release.Name }}
24 heritage: {{ .Release.Service }}
26 replicas: {{ .Values.replicaCount }}
30 app: {{ include "common.name" . }}
31 release: {{ .Release.Name }}
34 #dd775k: This container checks if the job that wait for all db instances to be up and initializes the db had finished.
39 # - "sleep 1000000000m"
43 - /tmp/vid-check-job-completion/vid_check_job_completion.py
51 fieldPath: metadata.namespace
52 image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
53 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
54 name: {{ include "common.name" . }}-readiness
56 - mountPath: /tmp/vid-check-job-completion
57 name: vid-check-job-completion
59 - name: {{ include "common.name" . }}
60 image: "{{ include "common.repository" . }}/{{ .Values.image }}"
61 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
65 command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/usr/local/tomcat/webapps/vid/WEB-INF/classes/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
67 - containerPort: {{ .Values.service.internalPort }}
68 # disable liveness probe when breakpoints set in debugger
69 # so K8s doesn't restart unresponsive container
70 {{- if eq .Values.liveness.enabled true }}
73 port: {{ .Values.service.internalPort }}
74 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
75 periodSeconds: {{ .Values.liveness.periodSeconds }}
79 port: {{ .Values.service.internalPort }}
80 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
81 periodSeconds: {{ .Values.readiness.periodSeconds }}
83 - name: ASDC_CLIENT_REST_HOST
84 value: sdc-be.{{ include "common.namespace" . }}
85 - name: ASDC_CLIENT_REST_AUTH
86 value: "{{ .Values.config.asdcclientrestauth }}"
87 - name: ASDC_CLIENT_REST_PORT
88 value: "{{ .Values.config.asdcclientrestport }}"
90 value: aai.{{ include "common.namespace" . }}
92 value: "{{ .Values.config.vidaaiport }}"
93 - name: VID_ECOMP_SHARED_CONTEXT_REST_URL
94 value: http://portal-app.{{ include "common.namespace" . }}:{{ .Values.config.onapport }}/ONAPPORTAL/context
95 - name: VID_MSO_SERVER_URL
96 value: http://so.{{ include "common.namespace" . }}:{{ .Values.config.msoport }}
98 value: "{{ .Values.config.vidmsopass }}"
99 - name: MSO_DME2_SERVER_URL
100 value: "{{ .Values.config.msodme2serverurl }}"
101 - name: MSO_DME2_ENABLED
102 value: {{ .Values.global.debugEnabled | default .Values.debugEnabled | quote }}
103 - name: VID_ECOMP_REDIRECT_URL
104 value: http://portal-app.{{ include "common.namespace" . }}:{{ .Values.config.onapport }}/ONAPPORTAL/login.htm
105 - name: VID_ECOMP_REST_URL
106 value: http://portal-app.{{ include "common.namespace" . }}:{{ .Values.config.onapport }}/ONAPPORTAL/auxapi
107 - name: VID_CONTACT_US_LINK
108 value: "{{ .Values.config.vidcontactuslink }}"
109 - name: VID_UEB_URL_LIST
110 value: message-router.{{ include "common.namespace" . }}
111 - name: VID_MYSQL_HOST
112 value: "{{ .Values.config.vidmysqlhost }}"
113 - name: VID_MYSQL_PORT
114 value: "{{ .Values.config.vidmysqlport }}"
115 - name: VID_MYSQL_DBNAME
116 value: "{{ .Values.config.vidmysqldbname }}"
117 - name: VID_MYSQL_USER
118 value: "{{ .Values.config.vidmysqluser }}"
119 - name: VID_MYSQL_PASS
120 value: "{{ .Values.config.vidmysqlpassword }}"
122 # secretKeyRef: {name: {{ include "common.fullname" . }}, key: vid-password}
123 - name: VID_MYSQL_MAXCONNECTIONS
124 value: "{{ .Values.config.vidmysqlmaxconnections }}"
126 - mountPath: /etc/localtime
129 - mountPath: /var/log/onap
131 - mountPath: /tmp/logback.xml
135 {{ toYaml .Values.resources | indent 12 }}
136 {{- if .Values.nodeSelector }}
138 {{ toYaml .Values.nodeSelector | indent 10 }}
140 {{- if .Values.affinity }}
142 {{ toYaml .Values.affinity | indent 10 }}
144 # side car containers
145 - name: filebeat-onap
146 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
147 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
149 - mountPath: /usr/share/filebeat/filebeat.yml
151 subPath: filebeat.yml
152 - mountPath: /var/log/onap
154 - mountPath: /usr/share/filebeat/data
155 name: vid-data-filebeat
160 - name: filebeat-conf
162 name: {{ include "common.fullname" . }}-filebeat-configmap
165 - name: vid-data-filebeat
169 name: {{ include "common.fullname" . }}-log-configmap
170 - name: vid-check-job-completion
172 name: {{ include "common.fullname" . }}-check-job-completion
174 - name: "{{ include "common.namespace" . }}-docker-registry-key"