apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: log-manager
spec:
  selector:
    matchLabels:
      app: log-manager
      version: v1.0.1
  template:
    metadata:
      labels:
        app: log-manager
        version: v1.0.1
    spec:
      containers:
        - name: manager
          image: blacklabelops/logrotate:1.3
          envFrom:
            - configMapRef:
                name: logrotate-config
          volumeMounts:
            - name: varlibdockercontainers
              mountPath: /var/lib/docker/containers
      volumes:
        - name: varlibdockercontainers
          hostPath:
            path: /var/lib/docker/containers
