---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: cosi-driver-sample
  labels:
    app.kubernetes.io/part-of: cosi-driver-sample
    app.kubernetes.io/component: driver
    app.kubernetes.io/name: cosi-driver-sample
spec:
  replicas: 1
  selector:
    matchLabels:
      app.kubernetes.io/part-of: cosi-driver-sample
      app.kubernetes.io/component: driver
      app.kubernetes.io/name: cosi-driver-sample
  template:
    metadata:
      labels:
        app.kubernetes.io/part-of: cosi-driver-sample
        app.kubernetes.io/component: driver
        app.kubernetes.io/name: cosi-driver-sample
    spec:
      serviceAccountName: cosi-driver-sample
      containers:
        - name: cosi-driver-sample
          image: cosi-driver-sample:latest
          args: ["-v", "2"]
          volumeMounts:
            - mountPath: /var/lib/cosi
              name: socket
        - name: objectstorage-driver-sidecar
          image: quay.io/containerobjectstorage/objectstorage-sidecar:canary
          env:
            - name: POD_NAMESPACE
              valueFrom:
                fieldRef:
                  fieldPath: metadata.namespace
          volumeMounts:
            - mountPath: /var/lib/cosi
              name: socket
      volumes:
        - name: socket
          emptyDir: {}
