apiVersion: apps/v1 kind: Deployment metadata: name: {{ include "spiffe-step-ssh.fullname" . }}-fetchca labels: {{- include "spiffe-step-ssh.labels" . | nindent 4 }} app: spiffe-step-ssh component: fetchca spec: {{- if not .Values.fetchCA.autoscaling.enabled }} replicas: {{ .Values.fetchCA.replicaCount }} {{- end }} selector: matchLabels: {{- include "spiffe-step-ssh.selectorLabels" . | nindent 6 }} app: spiffe-step-ssh component: fetchca template: metadata: {{- with .Values.podAnnotations }} annotations: {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "spiffe-step-ssh.labels" . | nindent 8 }} {{- with .Values.podLabels }} {{- toYaml . | nindent 8 }} {{- end }} app: spiffe-step-ssh component: fetchca spec: shareProcessNamespace: true {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} serviceAccountName: {{ include "spiffe-step-ssh.serviceAccountName" . }}-fetchca securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} initContainers: - name: busybox-volume image: {{ template "spire-lib.image" (dict "image" .Values.busybox.image "global" .Values.global) }} imagePullPolicy: {{ .Values.busybox.image.pullPolicy }} command: - sh - -c - 'cp -a /bin/busybox /busybox' volumeMounts: - name: busybox mountPath: /busybox resources: {{- toYaml .Values.fetchCA.spiffeHelper.resources | nindent 12 }} - name: init-tls image: {{ template "spire-lib.image" (dict "image" .Values.spiffeHelper.image "global" .Values.global) }} imagePullPolicy: {{ .Values.spiffeHelper.image.pullPolicy }} command: - /spiffe-helper - -config - /etc/spiffe-helper.conf - -daemon-mode=false volumeMounts: - name: spiffe-workload-api mountPath: /spiffe-workload-api readOnly: true - name: config mountPath: /etc/spiffe-helper.conf subPath: spiffe-helper-init.conf readOnly: true - name: certs mountPath: /certs resources: {{- toYaml .Values.fetchCA.spiffeHelper.resources | nindent 12 }} containers: - name: {{ .Chart.Name }}-fetchca securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: {{ template "spire-lib.image" (dict "image" .Values.nginx.image "global" .Values.global) }} imagePullPolicy: {{ .Values.nginx.image.pullPolicy }} command: - /bin/sh - -c - | echo $$$$ > /pid/pid cat > /etc/nginx/conf.d/ssl.conf <