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: apps/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 serviceName: {{ include "common.servicename" . }}-cluster
27 replicas: {{ .Values.replicaCount }}
28 podManagementPolicy: Parallel
32 app: {{ include "common.name" . }}
33 release: {{ .Release.Name }}
40 - {{ .Values.mysql.nameOverride }}
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" . }}-readiness
51 - name: {{ include "common.name" . }}
52 image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.image }}"
53 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
54 command: ["/bin/bash"]
55 args: ["-c", "/opt/sdnc/bin/startODL.sh"]
57 - containerPort: {{ .Values.service.internalPort }}
58 - containerPort: {{ .Values.service.internalPort2 }}
59 - containerPort: {{ .Values.service.internalPort3 }}
60 - containerPort: {{ .Values.service.clusterPort }}
63 port: {{ .Values.service.internalPort }}
64 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
65 periodSeconds: {{ .Values.readiness.periodSeconds }}
67 - name: MYSQL_ROOT_PASSWORD
70 name: {{ template "common.fullname" . }}
72 - name: SDNC_CONFIG_DIR
73 value: "{{ .Values.config.configDir }}"
74 - name: ENABLE_ODL_CLUSTER
75 value: "{{ .Values.config.enableClustering }}"
77 value: "{{ .Values.replicaCount }}"
79 value: "{{.Values.mysql.service.name}}.{{.Release.Namespace}}"
81 - mountPath: /etc/localtime
84 - mountPath: /opt/opendaylight/current/etc/org.ops4j.pax.logging.cfg
85 name: sdnc-logging-cfg-config
86 subPath: org.ops4j.pax.logging.cfg
87 - mountPath: /opt/onap/sdnc/bin/startODL.sh
90 - mountPath: /opt/onap/sdnc/bin/installSdncDb.sh
92 subPath: installSdncDb.sh
93 - mountPath: /opt/onap/sdnc/data/properties/aaiclient.properties
95 subPath: aaiclient.properties
96 - mountPath: /opt/onap/sdnc/data/properties/dblib.properties
97 name: sdnc-dblib-properties
98 subPath: dblib.properties
99 - mountPath: /opt/onap/sdnc/data/properties/svclogic.properties
100 name: sdnc-svclogic-config
101 subPath: svclogic.properties
102 - mountPath: /opt/onap/sdnc/svclogic/config/svclogic.properties
103 name: onap-sdnc-svclogic-config
104 subPath: svclogic.properties
105 - mountPath: {{ .Values.persistence.mdsalPath }}
106 name: {{ include "common.fullname" . }}-data
107 - mountPath: /var/log/onap
110 {{ toYaml .Values.resources | indent 12 }}
111 {{- if .Values.nodeSelector }}
113 {{ toYaml .Values.nodeSelector | indent 10 }}
115 {{- if .Values.affinity }}
117 {{ toYaml .Values.affinity | indent 10 }}
120 # side car containers
121 - name: filebeat-onap
122 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
123 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
125 - mountPath: /usr/share/filebeat/filebeat.yml
127 subPath: filebeat.yml
128 - mountPath: /var/log/onap
130 - mountPath: /usr/share/filebeat/data
133 - name: "{{ include "common.namespace" . }}-docker-registry-key"
140 - name: data-filebeat
142 - name: filebeat-conf
144 name: {{ include "common.fullname" . }}-filebeat-configmap
145 - name: sdnc-logging-cfg-config
147 name: {{ include "common.fullname" . }}-log-configmap
150 name: {{ include "common.fullname" . }}-startodl
155 - name: installsdncdb
157 name: {{ include "common.fullname" . }}-installsdncdb
159 - key: installSdncDb.sh
160 path: installSdncDb.sh
162 - name: aaiclient-conf
164 name: {{ include "common.fullname" . }}-aaiclient-properties
166 - key: aaiclient.properties
167 path: aaiclient.properties
169 - name: sdnc-dblib-properties
171 name: {{ include "common.fullname" . }}-dblib-properties
173 - key: dblib.properties
174 path: dblib.properties
176 - name: sdnc-svclogic-config
178 name: {{ include "common.fullname" . }}-svclogic-config
180 - key: svclogic.properties
181 path: svclogic.properties
183 - name: onap-sdnc-svclogic-config
185 name: {{ include "common.fullname" . }}-onap-sdnc-svclogic-config
187 - key: svclogic.properties
188 path: svclogic.properties
190 {{ if not .Values.persistence.enabled }}
191 - name: {{ include "common.fullname" . }}-data
194 volumeClaimTemplates:
196 name: {{ include "common.fullname" . }}-data
198 name: {{ include "common.fullname" . }}
200 accessModes: [ {{ .Values.persistence.accessMode }} ]
201 storageClassName: {{ include "common.fullname" . }}-data
204 storage: {{ .Values.persistence.size }}