1 # Copyright © 2018 Amdocs, Bell Canada, AT&T
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 replicas: {{ .Values.replicaCount }}
30 app: {{ include "common.name" . }}
31 release: {{ .Release.Name }}
34 - name: {{ include "common.name" . }}-chown
36 command: ["sh", "-c", "chown -R {{ .Values.config.ansibleUid }}:{{ .Values.config.ansibleGid}} {{ .Values.persistence.playbookPath }}"]
38 - mountPath: {{ .Values.persistence.playbookPath }}
39 name: {{ include "common.fullname" . }}-playbook
41 - name: {{ include "common.name" . }}
42 command: ["/bin/bash"]
43 args: ["-c", "cd /opt/onap/ccsdk && ./startAnsibleServer.sh"]
44 image: "{{ include "common.repository" . }}/{{ .Values.image }}"
45 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
47 - containerPort: {{ .Values.service.internalPort }}
48 # disable liveness probe when breakpoints set in debugger
49 # so K8s doesn't restart unresponsive container
50 {{ if .Values.liveness.enabled }}
53 port: {{ .Values.service.internalPort }}
54 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
55 periodSeconds: {{ .Values.liveness.periodSeconds }}
59 port: {{ .Values.service.internalPort }}
60 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
61 periodSeconds: {{ .Values.readiness.periodSeconds }}
63 - mountPath: /etc/localtime
66 - mountPath: {{ .Values.config.configDir }}/RestServer_config
68 subPath: RestServer_config
69 - mountPath: {{ .Values.persistence.playbookPath }}
70 name: {{ include "common.fullname" . }}-playbook
72 {{ include "common.resources" . | indent 12 }}
73 {{- if .Values.nodeSelector }}
75 {{ toYaml .Values.nodeSelector | indent 10 }}
77 {{- if .Values.affinity }}
79 {{ toYaml .Values.affinity | indent 10 }}
87 name: {{ include "common.fullname" . }}
89 {{ if not .Values.persistence.enabled }}
90 - name: {{ include "common.fullname" . }}-playbook
95 name: {{ include "common.fullname" . }}-playbook
97 name: {{ include "common.fullname" . }}
98 chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
99 release: "{{ .Release.Name }}"
100 heritage: "{{ .Release.Service }}"
103 - {{ .Values.persistence.accessMode }}
104 storageClassName: {{ include "common.storageClass" . }}
107 storage: {{ .Values.persistence.size }}