2 # Copyright © 2018 Amdocs, Bell Canada , ZTE
3 # Copyright © 2021 Orange
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
19 metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
21 selector: {{- include "common.selectors" . | nindent 4 }}
22 replicas: {{ .Values.replicaCount }}
24 metadata: {{- include "common.templateMetadata" . | nindent 6 }}
37 fieldPath: metadata.namespace
38 image: {{ include "repositoryGenerator.image.readiness" . }}
39 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
40 name: {{ include "common.name" . }}-readiness
42 - name: {{ include "common.name" . }}
43 image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
44 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
45 ports: {{- include "common.containerPorts" . | indent 10 }}
46 # disable liveness probe when breakpoints set in debugger
47 # so K8s doesn't restart unresponsive container
48 {{- if eq .Values.liveness.enabled true }}
51 port: {{ .Values.service.internalPort }}
52 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
53 periodSeconds: {{ .Values.liveness.periodSeconds }}
57 port: {{ .Values.service.internalPort }}
58 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
59 periodSeconds: {{ .Values.readiness.periodSeconds }}
62 value: msb-consul.{{ include "common.namespace" . }}
64 value: msb-discovery.{{ include "common.namespace" . }}
66 value: {{ .Values.config.routeLabels }}
68 - mountPath: /etc/localtime
71 - mountPath: /usr/local/apiroute-works/logs
72 name: {{ include "common.fullname" . }}-logs
73 resources: {{ include "common.resources" . | nindent 12 }}
74 {{- if .Values.nodeSelector }}
76 {{ toYaml .Values.nodeSelector | indent 10 }}
78 {{- if .Values.affinity }}
80 {{ toYaml .Values.affinity | indent 10 }}
83 {{ include "common.log.sidecar" . | nindent 8 }}
84 serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
86 - name: {{ include "common.fullname" . }}-log-conf
88 name: {{ include "common.fullname" . }}-log
89 {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
90 - name: {{ include "common.fullname" . }}-logs
96 - name: "{{ include "common.namespace" . }}-docker-registry-key"