2 # Copyright © 2017 Amdocs, Bell Canada
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.
19 metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
21 replicas: {{ .Values.replicaCount }}
22 selector: {{- include "common.selectors" . | nindent 4 }}
24 metadata: {{- include "common.templateMetadata" . | nindent 6 }}
31 - "cd /config-input && for PFILE in `ls -1 .`; do envsubst <${PFILE} >/config/${PFILE}; done"
34 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "db-secret" "key" "login") | indent 10 }}
36 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "db-secret" "key" "password") | indent 10 }}
38 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "rest-creds" "key" "login") | indent 10 }}
40 {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "rest-creds" "key" "password") | indent 10 }}
42 - mountPath: /config-input
46 image: {{ include "repositoryGenerator.image.envsubst" . }}
47 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
48 name: {{ include "common.name" . }}-update-config
54 - {{ .Values.config.sdncChartName }}
60 fieldPath: metadata.namespace
61 image: {{ include "repositoryGenerator.image.readiness" . }}
62 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
63 name: {{ include "common.name" . }}-readiness
65 - name: {{ include "common.name" . }}
66 command: ["/bin/bash"]
67 args: ["-c", "cd /opt/ansible-server && ./startAnsibleServer.sh"]
69 image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
70 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
71 ports: {{ include "common.containerPorts" . | nindent 12 }}
72 # disable liveness probe when breakpoints set in debugger
73 # so K8s doesn't restart unresponsive container
74 {{ if .Values.liveness.enabled }}
77 port: {{ .Values.service.internalPort }}
78 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
79 periodSeconds: {{ .Values.liveness.periodSeconds }}
83 port: {{ .Values.service.internalPort }}
84 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
85 periodSeconds: {{ .Values.readiness.periodSeconds }}
87 - mountPath: /etc/localtime
90 - mountPath: {{ .Values.config.configDir }}/RestServer_config
92 subPath: RestServer_config
93 resources: {{ include "common.resources" . | nindent 12 }}
94 {{- if .Values.nodeSelector }}
95 nodeSelector: {{ toYaml .Values.nodeSelector | nindent 8 }}
97 {{- if .Values.affinity }}
98 affinity: {{ toYaml .Values.affinity | nindent 8 }}
100 serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
107 name: {{ include "common.fullname" . }}
113 - name: "{{ include "common.namespace" . }}-docker-registry-key"