apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: mock-plugin
spec:
  selector:
    matchLabels:
      name: mock-plugin
  template:
    metadata:
      labels:
        name: mock-plugin
    spec:
      containers:
      - name: mock-plugin
        image: quay.io/k8scsi/mock-plugin
        env:
          - name: CSI_ENDPOINT
            value: unix:///socket/mock-csi-endpoint.sock
        securityContext:
          privileged: true
          allowPrivilegeEscalation: true
          capabilities:
            add: ["SYS_ADMIN"]
        volumeMounts:
        - name: mock
          mountPath: /socket
        - name: csi
          mountPath: /csi
          readOnly: true
      volumes:
      - name: mock
      - name: csi
        hostPath:
          path: /var/lib/kubelet/plugins

