apiVersion: apps/v1
kind: DaemonSet
metadata:
  labels:
    app: node-exporter
  name: node-exporter
spec:
  selector:
    matchLabels:
      app: node-exporter
  template:
    metadata:
      labels:
        app: node-exporter
    spec:
      containers:
        - name: node-exporter
          image: prom/node-exporter:v0.16.0
          args:
            - --path.procfs=/host/proc
            - --path.sysfs=/host/sys
          ports:
            - name: metrics
              containerPort: 9100
          volumeMounts:
            - name: proc
              mountPath: /host/proc
              readOnly:  true
            - name: sys
              mountPath: /host/sys
              readOnly: true
      hostNetwork: true
      hostPID: true
      tolerations:
        - key: node-role.kubernetes.io/master
        - key: dedicated.deckhouse.io
          operator: Exists
        - key: dedicated
          operator: Exists
        - key: node.kubernetes.io/not-ready
        - key: node.kubernetes.io/out-of-disk
        - key: node.kubernetes.io/memory-pressure
        - key: node.kubernetes.io/disk-pressure
        - key: CriticalAddonsOnly
          operator: Exists
      volumes:
        - name: proc
          hostPath:
            path: /proc
        - name: sys
          hostPath:
            path: /sys
