apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: intel-dsa-plugin
  labels:
    app: intel-dsa-plugin
spec:
  selector:
    matchLabels:
      app: intel-dsa-plugin
  template:
    metadata:
      labels:
        app: intel-dsa-plugin
    spec:
      containers:
      - name: intel-dsa-plugin
        env:
          - name: NODE_NAME
            valueFrom:
              fieldRef:
                fieldPath: spec.nodeName
        image: intel/intel-dsa-plugin:devel
        imagePullPolicy: IfNotPresent
        securityContext:
          readOnlyRootFilesystem: true
          allowPrivilegeEscalation: false
        volumeMounts:
        - name: devfs
          mountPath: /dev/dsa
          readOnly: true
        - name: chardevs
          mountPath: /dev/char
          readOnly: true
        - name: sysfs
          mountPath: /sys/bus/dsa
          readOnly: true
        - name: kubeletsockets
          mountPath: /var/lib/kubelet/device-plugins
      volumes:
      - name: devfs
        hostPath:
          path: /dev/dsa
      - name: chardevs
        hostPath:
          path: /dev/char
      - name: sysfs
        hostPath:
          path: /sys/bus/dsa
      - name: kubeletsockets
        hostPath:
          path: /var/lib/kubelet/device-plugins
      nodeSelector:
        kubernetes.io/arch: amd64
