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: "{{ include "common.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: ODL_ADMIN_PASSWORD
75 name: {{ template "common.fullname" . }}-odl
77 - name: SDNC_DB_PASSWORD
80 name: {{ template "common.fullname" . }}-sdnctl
81 key: db-sdnctl-password
82 - name: SDNC_CONFIG_DIR
83 value: "{{ .Values.config.configDir }}"
84 - name: ENABLE_ODL_CLUSTER
85 value: "{{ .Values.config.enableClustering }}"
86 - name: MY_ODL_CLUSTER
87 value: "{{ .Values.config.myODLCluster }}"
88 - name: PEER_ODL_CLUSTER
89 value: "{{ .Values.config.peerODLCluster }}"
90 - name: IS_PRIMARY_CLUSTER
91 value: "{{ .Values.config.isPrimaryCluster }}"
93 value: "{{ .Values.config.geoEnabled}}"
95 value: "{{ .Values.replicaCount }}"
97 value: "{{.Release.Name}}-{{.Values.mysql.nameOverride}}-0.{{.Values.mysql.service.name}}.{{.Release.Namespace}}"
99 - mountPath: /etc/localtime
102 - mountPath: /opt/opendaylight/current/etc/org.ops4j.pax.logging.cfg
103 name: sdnc-logging-cfg-config
104 subPath: org.ops4j.pax.logging.cfg
105 - mountPath: {{ .Values.config.binDir }}/startODL.sh
108 - mountPath: {{ .Values.config.binDir }}/installSdncDb.sh
110 subPath: installSdncDb.sh
111 - mountPath: {{ .Values.config.configDir }}/aaiclient.properties
113 subPath: aaiclient.properties
114 - mountPath: {{ .Values.config.configDir }}/dblib.properties
116 subPath: dblib.properties
117 - mountPath: {{ .Values.config.configDir }}/lcm-dg.properties
119 subPath: lcm-dg.properties
120 - mountPath: {{ .Values.config.configDir }}/svclogic.properties
122 subPath: svclogic.properties
123 - mountPath: /opt/onap/sdnc/svclogic/config/svclogic.properties
125 subPath: svclogic.properties
126 - mountPath: {{ .Values.config.configDir }}/netbox.properties
128 subPath: netbox.properties
129 - mountPath: {{ .Values.config.configDir }}/blueprints-processor-adaptor.properties
131 subPath: blueprints-processor-adaptor.properties
132 - mountPath: {{ .Values.persistence.mdsalPath }}
133 name: {{ include "common.fullname" . }}-mdsal
134 - mountPath: /var/log/onap
137 {{ include "common.resources" . | indent 12 }}
138 {{- if .Values.nodeSelector }}
140 {{ toYaml .Values.nodeSelector | indent 10 }}
142 {{- if .Values.affinity }}
144 {{ toYaml .Values.affinity | indent 10 }}
147 # side car containers
148 - name: filebeat-onap
149 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
150 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
152 - mountPath: /usr/share/filebeat/filebeat.yml
154 subPath: filebeat.yml
155 - mountPath: /var/log/onap
157 - mountPath: /usr/share/filebeat/data
160 - name: "{{ include "common.namespace" . }}-docker-registry-key"
167 - name: data-filebeat
169 - name: filebeat-conf
171 name: {{ include "common.fullname" . }}-filebeat-configmap
172 - name: sdnc-logging-cfg-config
174 name: {{ include "common.fullname" . }}-log-configmap
177 name: {{ include "common.fullname" . }}-bin
181 name: {{ include "common.fullname" . }}-properties
183 {{ if not .Values.persistence.enabled }}
184 - name: {{ include "common.fullname" . }}-mdsal
187 volumeClaimTemplates:
189 name: {{ include "common.fullname" . }}-mdsal
191 name: {{ include "common.fullname" . }}
193 accessModes: [ {{ .Values.persistence.accessMode }} ]
194 storageClassName: {{ include "common.fullname" . }}-mdsal
197 storage: {{ .Values.persistence.size }}