apiVersion: extensions/v1beta1 kind: DaemonSet metadata: name: rdma-device-plugin-daemonset namespace: kube-system spec: template: metadata: # Mark this pod as a critical add-on; when enabled, the critical add-on scheduler # reserves resources for critical add-on pods so that they can be rescheduled after # a failure. This annotation works in tandem with the toleration below. annotations: scheduler.alpha.kubernetes.io/critical-pod: "" labels: name: rdma-device-plugin-ds spec: tolerations: # Allow this pod to be rescheduled while the node is in "critical add-ons only" mode. # This, along with the annotation above marks this pod as a critical add-on. - key: CriticalAddonsOnly operator: Exists - effect: NoSchedule operator: Exists hostNetwork: true containers: - image: nimbix/k8s-rdma-device-plugin:1.10-bionic imagePullPolicy: Always name: rdma-device-plugin-ctr args: ["-log-level", "debug"] securityContext: # SELinux option needs to be set for RHEL OS seLinuxOptions: type: "container_runtime_t" allowPrivilegeEscalation: false capabilities: drop: ["ALL"] volumeMounts: - name: device-plugin mountPath: /var/lib/kubelet/device-plugins volumes: - name: device-plugin hostPath: path: /var/lib/kubelet/device-plugins