---
# Source: falco-exporter/templates/daemonset.yaml
apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: falco-exporter
  labels:
    app.kubernetes.io/name: falco-exporter
    app.kubernetes.io/instance: falco-exporter
    app.kubernetes.io/version: "0.3.0"
spec:
  selector:
    matchLabels:
      app.kubernetes.io/name: falco-exporter
      app.kubernetes.io/instance: falco-exporter
  template:
    metadata:
      labels:
        app.kubernetes.io/name: falco-exporter
        app.kubernetes.io/instance: falco-exporter
    spec:
      serviceAccountName: falco-exporter
      securityContext:
        {}
      containers:
        - name: falco-exporter
          securityContext:
            {}
          image: "falcosecurity/falco-exporter:latest"
          imagePullPolicy: IfNotPresent
          args:
            - /usr/bin/falco-exporter
            - --client-socket=unix:///var/run/falco/falco.sock
            - --timeout=2m
            - --listen-address=0.0.0.0:9376
          ports:
            - name: metrics
              containerPort: 9376
              protocol: TCP
          livenessProbe:
            httpGet:
              path: /metrics
              port: 9376
          readinessProbe:
            httpGet:
              path: /readiness
              port: 9376
          resources:
            {}
          volumeMounts:
            - mountPath: /var/run/falco
              name: falco-socket-dir
              readOnly: true
      volumes:
        - name: falco-socket-dir
          hostPath: 
            path: /var/run/falco
      tolerations:
        - effect: NoSchedule
          key: node-role.kubernetes.io/master
