apiVersion: apps/v1
kind: Deployment
metadata:
  name: minio
  labels:
    app: minio
spec:
  selector:
    matchLabels:
      app: minio
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        app: minio
    spec:
      containers:
        - name: minio
          image: gcr.io/ml-pipeline/minio:RELEASE.2019-08-14T20-37-41Z-license-compliance
          args:
            - gateway
            - gcs
          env:
            - name: MINIO_ACCESS_KEY
              value: "minio"
            - name: MINIO_SECRET_KEY
              value: "minio123"
            - name: GOOGLE_APPLICATION_CREDENTIALS
              value: "/etc/credentials/application_default_credentials.json"
          ports:
            - containerPort: 9000
          volumeMounts:
            - name: gcp-sa-token
              mountPath: "/etc/credentials"
              readOnly: true
      volumes:
        - name: gcp-sa-token
          secret:
            secretName: user-gcp-sa