apiVersion: apps/v1 kind: Deployment metadata: name: {{ include "act_runner.fullname" . }} labels: {{- include "act_runner.labels" . | nindent 4 }} spec: {{- if not .Values.autoscaling.enabled }} replicas: {{ .Values.replicaCount }} {{- end }} selector: matchLabels: {{- include "act_runner.selectorLabels" . | nindent 6 }} template: metadata: {{- with .Values.podAnnotations }} annotations: {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "act_runner.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} serviceAccountName: {{ include "act_runner.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 }} resources: {{- toYaml .Values.resources | nindent 12 }} env: - name: DOCKER_HOST value: "tcp://localhost:2375" - name: DOCKER_TLS_CERTDIR value: "" - name: ACT_INSTANCE value: {{ .Values.act_runner.instance }} - name: ACT_TOKEN valueFrom: secretKeyRef: name: {{ include "act_runner.fullname" . }}-secret key: act-runner-token - name: ACT_LABELS value: {{ join "," .Values.act_runner.labels }} volumeMounts: - name: docker-data mountPath: /shared - name: {{ include "act_runner.fullname" . }}-pvc mountPath: /opt/act_runner - name: act-runner-dind securityContext: privileged: true image: docker:23.0.0-dind imagePullPolicy: IfNotPresent env: - name: DOCKER_DRIVER value: "overlay2" - name: DOCKER_TLS_CERTDIR value: "" volumeMounts: - name: docker-data mountPath: /shared volumes: - name: docker-data emptyDir: - name: {{ include "act_runner.fullname" . }}-pvc persistentVolumeClaim: claimName: {{ include "act_runner.fullname" . }}-pvc {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }}