apiVersion: v1 kind: Service metadata: name: {{ include "covidok.minio" . }} labels: {{- include "covidok.labels" . | nindent 4 }} spec: ports: - port: 9000 selector: {{- include "covidok.selectorLabels" . | nindent 4 }} app: minio-covidok --- apiVersion: apps/v1 # for versions before 1.9.0 use apps/v1beta2 kind: Deployment metadata: name: {{ include "covidok.minio" . }} spec: selector: matchLabels: {{- include "covidok.selectorLabels" . | nindent 6 }} app: minio-covidok strategy: type: Recreate template: metadata: {{- with .Values.podAnnotations }} annotations: {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "covidok.selectorLabels" . | nindent 8 }} app: minio-covidok spec: containers: - image: "{{ .Values.images.minio.name }}:{{ .Values.images.minio.tag }}" name: minio env: - name: MINIO_ACCESS_KEY value: "{{ .Values.config.minio.accesskey }}" - name: MINIO_SECRET_KEY value: "{{ .Values.config.minio.secretkey }}" ports: - containerPort: 9000 name: minio command: ["minio"] args: ["server", "/data"] livenessProbe: httpGet: path: /minio/health/live port: 9000 scheme: HTTP initialDelaySeconds: 120 periodSeconds: 15 timeoutSeconds: 10 successThreshold: 1 failureThreshold: 3 {{ if .Values.persistence.enabled }} volumeMounts: - name: minio-data mountPath: /data volumes: - name: minio-data persistentVolumeClaim: claimName: minio-pvc-{{ .Release.Name }} --- apiVersion: v1 kind: PersistentVolumeClaim metadata: name: minio-pvc-{{ .Release.Name }} labels: {{- include "covidok.labels" . | nindent 4 }} spec: storageClassName: {{ .Values.persistence.storageClass }} accessModes: - ReadWriteOnce resources: requests: storage: {{ .Values.persistence.claimSize }} {{ end }}