2 # Copyright © 2017 Amdocs, Bell Canada
3 # Copyright (C) 2020 Wipro Limited.
4 # Modifications Copyright © 2018 AT&T,VMware
6 # Licensed under the Apache License, Version 2.0 (the "License");
7 # you may not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
10 # http://www.apache.org/licenses/LICENSE-2.0
12 # Unless required by applicable law or agreed to in writing, software
13 # distributed under the License is distributed on an "AS IS" BASIS,
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 # See the License for the specific language governing permissions and
16 # limitations under the License.
22 name: {{ include "common.fullname" . }}
23 namespace: {{ include "common.namespace" . }}
25 app: {{ include "common.name" . }}
26 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
27 release: {{ include "common.release" . }}
28 heritage: {{ .Release.Service }}
32 app: {{ include "common.name" . }}
33 replicas: {{ .Values.replicaCount }}
37 app: {{ include "common.name" . }}
38 release: {{ include "common.release" . }}
41 - name: {{ include "common.name" . }}-readiness
54 fieldPath: metadata.namespace
55 image: {{ include "repositoryGenerator.image.readiness" . }}
56 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
58 - name: {{ include "common.name" . }}-onboard-readiness
63 - "{{ include "common.release" . }}-oof-has-onboard"
69 fieldPath: metadata.namespace
70 image: {{ include "repositoryGenerator.image.readiness" . }}
71 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
73 - name: {{ include "common.name" . }}-has-sms-readiness
78 until [ $resp = "200" ]; do
79 resp=$(curl -s -o /dev/null -k --write-out %{http_code} https://aaf-sms.{{ include "common.namespace" . }}:10443/v1/sms/domain/has/secret);
88 fieldPath: metadata.namespace
89 image: {{ include "repositoryGenerator.image.curl" . }}
90 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
91 {{ include "common.certInitializer.initContainer" . | indent 6 }}
94 - name: {{ include "common.name" . }}
95 image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }}
96 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
97 command: ["/bin/bash","-c"]
98 args: ["/usr/local/bin/uwsgi -s /run/conductor/uwsgi.sock --chmod-socket=777 --wsgi-file /etc/nginx/conductor.wsgi --callable application --set port={{ .Values.uwsgi.internalPort }} --die-on-term --exit-on-reload --pidfile /run/conductor/conductor-uwsgi.pid --enable-threads --workers 6 --master --vacuum --single-interpreter --socket-timeout 10 --max-worker-lifetime 300 --max-requests 100 --no-defer-accept --protocol=uwsgi --socket 0.0.0.0:{{ .Values.uwsgi.internalPort }}"]
100 - containerPort: {{ .Values.uwsgi.internalPort }}
101 # disable liveness probe when breakpoints set in debugger
102 # so K8s doesn't restart unresponsive container
103 {{- if .Values.liveness.enabled }}
106 port: {{ .Values.uwsgi.internalPort }}
107 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
108 periodSeconds: {{ .Values.liveness.periodSeconds }}
112 port: {{ .Values.uwsgi.internalPort }}
113 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
114 periodSeconds: {{ .Values.readiness.periodSeconds }}
117 - mountPath: /etc/localtime
120 - mountPath: /usr/local/etc/conductor/conductor.conf
121 name: {{ .Values.global.commonConfigPrefix }}-config
122 subPath: conductor.conf
123 - mountPath: /usr/local/bin/log.conf
124 name: {{ .Values.global.commonConfigPrefix }}-config
126 - mountPath: /usr/local/bin/AAF_RootCA.cer
127 name: {{ include "common.fullname" . }}-onap-certs
128 subPath: aaf_root_ca.cer
130 {{ include "common.resources" . | indent 12 }}
131 - name: {{ include "common.name" . }}-nginx
132 image: {{ include "repositoryGenerator.image.nginx" . }}
133 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
139 grep -v '^$' /opt/bitnami/nginx/ssl/local/org.onap.oof.crt > /tmp/oof.crt
140 cat /tmp/oof.crt /tmp/intermediate_root_ca.pem /tmp/AAF_RootCA.cer >> /opt/bitnami/nginx/org.onap.oof.crt
141 /opt/bitnami/scripts/nginx/entrypoint.sh /opt/bitnami/scripts/nginx/run.sh
143 - containerPort: {{ .Values.service.internalPort }}
144 {{- if .Values.liveness.enabled }}
147 port: {{ .Values.service.internalPort }}
148 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
149 periodSeconds: {{ .Values.liveness.periodSeconds }}
153 port: {{ .Values.service.internalPort }}
154 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
155 periodSeconds: {{ .Values.readiness.periodSeconds }}
157 {{ include "common.certInitializer.volumeMount" . | indent 10 }}
158 - mountPath: /etc/localtime
161 - mountPath: /opt/bitnami/nginx/conf/nginx.conf
162 name: {{ .Values.global.commonConfigPrefix }}-config
164 - mountPath: /tmp/AAF_RootCA.cer
165 name: {{ include "common.fullname" . }}-onap-certs
166 subPath: aaf_root_ca.cer
167 - mountPath: /tmp/intermediate_root_ca.pem
168 name: {{ include "common.fullname" . }}-onap-certs
169 subPath: intermediate_root_ca.pem
171 {{ include "common.resources" . | indent 12 }}
172 {{- if .Values.nodeSelector }}
174 {{ toYaml .Values.nodeSelector | indent 10 }}
176 {{- if .Values.affinity }}
178 {{ toYaml .Values.affinity | indent 10 }}
181 {{ include "common.certInitializer.volumes" . | nindent 8 }}
185 - name: {{ .Values.global.commonConfigPrefix }}-config
187 name: {{ .Values.global.commonConfigPrefix }}-configmap
191 - key: conductor.conf
195 {{ include "oof.certificate.volume" . | indent 8 }}
197 - name: "{{ include "common.namespace" . }}-docker-registry-key"