1 # Copyright © 2017 Amdocs, Bell Canada
2 # Modifications Copyright © 2018 AT&T
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: {{ .Release.Name }}
25 heritage: {{ .Release.Service }}
27 replicas: {{ .Values.replicaCount }}
30 app: {{ include "common.name" . }}
34 app: {{ include "common.name" . }}
35 release: {{ .Release.Name }}
36 name: {{ include "common.name" . }}
38 checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
39 msb.onap.org/service-info: '[
41 "serviceName": "_aai-cloudInfrastructure",
43 "url": "/aai/v11/cloud-infrastructure",
47 "lb_policy":"ip_hash",
49 "path": "/aai/v11/cloud-infrastructure"
52 "serviceName": "_aai-cloudInfrastructure",
54 "url": "/aai/v12/cloud-infrastructure",
58 "lb_policy":"ip_hash",
60 "path": "/aai/v12/cloud-infrastructure"
63 "serviceName": "_aai-cloudInfrastructure",
65 "url": "/aai/v13/cloud-infrastructure",
69 "lb_policy":"ip_hash",
71 "path": "/aai/v13/cloud-infrastructure"
74 "serviceName": "_aai-business",
76 "url": "/aai/v11/business",
80 "lb_policy":"ip_hash",
82 "path": "/aai/v11/business"
85 "serviceName": "_aai-business",
87 "url": "/aai/v12/business",
91 "lb_policy":"ip_hash",
93 "path": "/aai/v12/business"
96 "serviceName": "_aai-business",
98 "url": "/aai/v13/business",
102 "lb_policy":"ip_hash",
104 "path": "/aai/v13/business"
107 "serviceName": "_aai-actions",
109 "url": "/aai/v11/actions",
113 "lb_policy":"ip_hash",
115 "path": "/aai/v11/actions"
118 "serviceName": "_aai-actions",
120 "url": "/aai/v12/actions",
124 "lb_policy":"ip_hash",
126 "path": "/aai/v12/actions"
129 "serviceName": "_aai-actions",
131 "url": "/aai/v13/actions",
135 "lb_policy":"ip_hash",
137 "path": "/aai/v13/actions"
140 "serviceName": "_aai-service-design-and-creation",
142 "url": "/aai/v11/service-design-and-creation",
146 "lb_policy":"ip_hash",
148 "path": "/aai/v11/service-design-and-creation"
151 "serviceName": "_aai-service-design-and-creation",
153 "url": "/aai/v12/service-design-and-creation",
157 "lb_policy":"ip_hash",
159 "path": "/aai/v12/service-design-and-creation"
162 "serviceName": "_aai-service-design-and-creation",
164 "url": "/aai/v13/service-design-and-creation",
168 "lb_policy":"ip_hash",
170 "path": "/aai/v13/service-design-and-creation"
173 "serviceName": "_aai-network",
175 "url": "/aai/v11/network",
179 "lb_policy":"ip_hash",
181 "path": "/aai/v11/network"
184 "serviceName": "_aai-network",
186 "url": "/aai/v12/network",
190 "lb_policy":"ip_hash",
192 "path": "/aai/v12/network"
195 "serviceName": "_aai-network",
197 "url": "/aai/v13/network",
201 "lb_policy":"ip_hash",
203 "path": "/aai/v13/network"
206 "serviceName": "_aai-externalSystem",
208 "url": "/aai/v11/external-system",
212 "lb_policy":"ip_hash",
214 "path": "/aai/v11/external-system"
217 "serviceName": "_aai-externalSystem",
219 "url": "/aai/v12/external-system",
223 "lb_policy":"ip_hash",
225 "path": "/aai/v12/external-system"
228 "serviceName": "_aai-externalSystem",
230 "url": "/aai/v13/external-system",
234 "lb_policy":"ip_hash",
236 "path": "/aai/v13/external-system"
239 "serviceName": "aai-cloudInfrastructure",
241 "url": "/aai/v11/cloud-infrastructure",
245 "lb_policy":"ip_hash",
249 "serviceName": "aai-cloudInfrastructure",
251 "url": "/aai/v12/cloud-infrastructure",
255 "lb_policy":"ip_hash",
259 "serviceName": "aai-cloudInfrastructure",
261 "url": "/aai/v13/cloud-infrastructure",
265 "lb_policy":"ip_hash",
269 "serviceName": "aai-business",
271 "url": "/aai/v11/business",
275 "lb_policy":"ip_hash",
279 "serviceName": "aai-business",
281 "url": "/aai/v12/business",
285 "lb_policy":"ip_hash",
289 "serviceName": "aai-business",
291 "url": "/aai/v13/business",
295 "lb_policy":"ip_hash",
299 "serviceName": "aai-actions",
301 "url": "/aai/v11/actions",
305 "lb_policy":"ip_hash",
309 "serviceName": "aai-actions",
311 "url": "/aai/v12/actions",
315 "lb_policy":"ip_hash",
319 "serviceName": "aai-actions",
321 "url": "/aai/v13/actions",
325 "lb_policy":"ip_hash",
329 "serviceName": "aai-service-design-and-creation",
331 "url": "/aai/v11/service-design-and-creation",
335 "lb_policy":"ip_hash",
339 "serviceName": "aai-service-design-and-creation",
341 "url": "/aai/v12/service-design-and-creation",
345 "lb_policy":"ip_hash",
349 "serviceName": "aai-service-design-and-creation",
351 "url": "/aai/v13/service-design-and-creation",
355 "lb_policy":"ip_hash",
359 "serviceName": "aai-network",
361 "url": "/aai/v11/network",
365 "lb_policy":"ip_hash",
369 "serviceName": "aai-network",
371 "url": "/aai/v12/network",
375 "lb_policy":"ip_hash",
379 "serviceName": "aai-network",
381 "url": "/aai/v13/network",
385 "lb_policy":"ip_hash",
389 "serviceName": "aai-externalSystem",
391 "url": "/aai/v11/external-system",
395 "lb_policy":"ip_hash",
399 "serviceName": "aai-externalSystem",
401 "url": "/aai/v12/external-system",
405 "lb_policy":"ip_hash",
409 "serviceName": "aai-externalSystem",
411 "url": "/aai/v13/external-system",
415 "lb_policy":"ip_hash",
420 hostname: aai-resources
421 {{ if .Values.global.initContainers.enabled }}
424 {{ if .Values.global.jobs.createSchema.enabled }}
425 - /root/job_complete.py
428 - {{ .Release.Name }}-aai-graphadmin-create-db-schema
440 fieldPath: metadata.namespace
441 image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
442 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
443 name: {{ include "common.name" . }}-readiness
446 - name: {{ include "common.name" . }}
447 image: "{{ include "common.repository" . }}/{{ .Values.image }}"
448 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
450 - name: LOCAL_USER_ID
451 value: {{ .Values.global.config.userId | quote }}
452 - name: LOCAL_GROUP_ID
453 value: {{ .Values.global.config.groupId | quote }}
455 - mountPath: /etc/localtime
458 - mountPath: /opt/app/aai-resources/resources/etc/appprops/janusgraph-realtime.properties
459 name: {{ include "common.fullname" . }}-db-real-conf
460 subPath: janusgraph-realtime.properties
461 - mountPath: /opt/app/aai-resources/resources/etc/appprops/janusgraph-cached.properties
462 name: {{ include "common.fullname" . }}-db-cached-conf
463 subPath: janusgraph-cached.properties
464 - mountPath: /opt/app/aai-resources/resources/etc/appprops/aaiconfig.properties
465 name: {{ include "common.fullname" . }}-aaiconfig-conf
466 subPath: aaiconfig.properties
467 - mountPath: /opt/aai/logroot/AAI-RES
468 name: {{ include "common.fullname" . }}-logs
469 - mountPath: /opt/app/aai-resources/resources/logback.xml
470 name: {{ include "common.fullname" . }}-log-conf
472 - mountPath: /opt/app/aai-resources/resources/localhost-access-logback.xml
473 name: {{ include "common.fullname" . }}-localhost-access-log-conf
474 subPath: localhost-access-logback.xml
475 - mountPath: /opt/app/aai-resources/resources/aaf/org.onap.aai.keyfile
476 name: {{ include "common.fullname" . }}-aaf-certs
477 subPath: org.onap.aai.keyfile
478 - mountPath: /opt/app/aai-resources/resources/aaf/org.onap.aai.props
479 name: {{ include "common.fullname" . }}-aaf-properties
480 subPath: org.onap.aai.props
481 - mountPath: /opt/app/aai-resources/resources/aaf/org.osaaf.location.props
482 name: {{ include "common.fullname" . }}-aaf-properties
483 subPath: org.osaaf.location.props
484 - mountPath: /opt/app/aai-resources/resources/aaf/permissions.properties
485 name: {{ include "common.fullname" . }}-aaf-properties
486 subPath: permissions.properties
487 - mountPath: /opt/app/aai-resources/resources/cadi.properties
488 name: {{ include "common.fullname" . }}-aaf-properties
489 subPath: cadi.properties
490 - mountPath: /opt/app/aai-resources/resources/aaf/org.onap.aai.p12
491 name: {{ include "common.fullname" . }}-aaf-certs
492 subPath: org.onap.aai.p12
493 - mountPath: /opt/app/aai-resources/resources/aaf/truststoreONAPall.jks
494 name: {{ include "common.fullname" . }}-aaf-certs
495 subPath: truststoreONAPall.jks
496 - mountPath: /opt/app/aai-resources/resources/application.properties
497 name: {{ include "common.fullname" . }}-springapp-conf
498 subPath: application.properties
500 {{ range $job := .Values.global.config.auth.files }}
501 - mountPath: /opt/app/aai-resources/resources/etc/auth/{{ . }}
502 name: {{ include "common.fullname" $global }}-auth-truststore-sec
506 - containerPort: {{ .Values.service.internalPort }}
507 - containerPort: {{ .Values.service.internalPort2 }}
508 # disable liveness probe when breakpoints set in debugger
509 # so K8s doesn't restart unresponsive container
510 {{ if .Values.liveness.enabled }}
513 port: {{ .Values.service.internalPort }}
514 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
515 periodSeconds: {{ .Values.liveness.periodSeconds }}
519 port: {{ .Values.service.internalPort }}
520 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
521 periodSeconds: {{ .Values.readiness.periodSeconds }}
523 {{ include "common.resources" . | indent 12 }}
524 {{- if .Values.nodeSelector }}
526 {{ toYaml .Values.nodeSelector | indent 8 }}
528 {{- if .Values.affinity }}
530 {{ toYaml .Values.affinity | indent 8 }}
533 # side car containers
534 - name: filebeat-onap
535 image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
536 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
538 - mountPath: /usr/share/filebeat/filebeat.yml
539 subPath: filebeat.yml
541 - mountPath: /var/log/onap
542 name: {{ include "common.fullname" . }}-logs
543 - mountPath: /usr/share/filebeat/data
544 name: {{ include "common.fullname" . }}-filebeat
550 - name: filebeat-conf
553 - name: {{ include "common.fullname" . }}-logs
555 - name: {{ include "common.fullname" . }}-filebeat
557 - name: {{ include "common.fullname" . }}-log-conf
559 name: {{ include "common.fullname" . }}-log
560 - name: {{ include "common.fullname" . }}-localhost-access-log-conf
562 name: {{ include "common.fullname" . }}-localhost-access-log-configmap
563 - name: {{ include "common.fullname" . }}-db-real-conf
565 name: {{ include "common.fullname" . }}-db-real-configmap
566 - name: {{ include "common.fullname" . }}-db-cached-conf
568 name: {{ include "common.fullname" . }}-db-cached-configmap
569 - name: {{ include "common.fullname" . }}-aaiconfig-conf
571 name: {{ include "common.fullname" . }}-aaiconfig-configmap
572 - name: {{ include "common.fullname" . }}-aaf-properties
574 name: {{ include "common.fullname" . }}-aaf-props
575 - name: {{ include "common.fullname" . }}-aaf-certs
577 secretName: {{ include "common.fullname" . }}-aaf-keys
578 - name: {{ include "common.fullname" . }}-springapp-conf
580 name: {{ include "common.fullname" . }}-springapp-configmap
581 - name: {{ include "common.fullname" . }}-realm-conf
583 name: {{ include "common.fullname" . }}-realm-configmap
584 - name: {{ include "common.fullname" . }}-auth-truststore-sec
586 secretName: aai-auth-truststore-secret
588 {{ range $job := .Values.global.config.auth.files }}
592 restartPolicy: {{ .Values.restartPolicy }}
594 - name: "{{ include "common.namespace" . }}-docker-registry-key"