apiVersion: apps/v1 kind: Deployment metadata: name: {{ include "common.fullname" . }} labels: {{- include "common.labels" . | nindent 4 }} spec: replicas: 1 selector: matchLabels: {{- include "common.selectorLabels" . | nindent 6 }} template: metadata: annotations: checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} checksum/secret: {{ include (print $.Template.BasePath "/secrets.yaml") . | sha256sum }} {{- with .Values.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "common.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.registry }}/{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} envFrom: {{- if .Values.existingConfigmap }} - configMapRef: name: {{ .Values.existingConfigmap }} {{- else }} - configMapRef: name: {{ include "common.fullname" . }} {{- end }} {{- if .Values.existingSecret }} - secretRef: name: {{ .Values.existingSecret }} {{- else }} - secretRef: name: {{ include "common.fullname" . }} {{- end }} {{- if .Values.extraEnvVarsSecret }} - secretRef: name: {{ .Values.extraEnvVarsSecret }} {{- end }} ports: - name: http containerPort: 5678 protocol: TCP livenessProbe: httpGet: path: /healthz port: http readinessProbe: httpGet: path: /healthz port: http startupProbe: httpGet: path: /healthz port: http failureThreshold: 30 periodSeconds: 10 resources: {{- toYaml .Values.resources | nindent 12 }} {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }}