apiVersion: apps/v1 kind: Deployment metadata: name: {{ include "nikita-tokarch-uk.fullname" . }} labels: {{- include "nikita-tokarch-uk.labels" . | nindent 4 }} spec: replicas: {{ .Values.replicaCount }} selector: matchLabels: {{- include "nikita-tokarch-uk.selectorLabels" . | nindent 6 }} template: metadata: annotations: checksum/config: {{ include ( print $.Template.BasePath "/config.yaml" ) . | sha256sum }} {{- with .Values.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "nikita-tokarch-uk.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} serviceAccountName: {{ include "nikita-tokarch-uk.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} command: - /usr/sbin/nginx ports: - name: http containerPort: 80 protocol: TCP livenessProbe: httpGet: path: /version.html port: http readinessProbe: httpGet: path: /version.html port: http resources: {{- toYaml .Values.resources | nindent 12 }} - name: {{ .Chart.Name }}-renderer securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} workingDir: /etc/nikita-tokarch-uk command: - /usr/local/bin/nikita-tokarch-uk-frontend resources: {{- toYaml .Values.resources | nindent 12 }} volumeMounts: - name: "{{ include "nikita-tokarch-uk.fullname" . }}-config" mountPath: /etc/nikita-tokarch-uk readOnly: true volumes: - name: "{{ template "nikita-tokarch-uk.fullname" . }}-config" {{- if .Values.config }} configMap: name: "{{ include "nikita-tokarch-uk.fullname" . }}-config" {{- else }} emptyDir: {} {{- end }} {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }}