diff --git a/collectd.container b/collectd.container new file mode 100644 index 0000000..e257c45 --- /dev/null +++ b/collectd.container @@ -0,0 +1,21 @@ +# vim: set ft=systemd : +[Unit] +Description=Collectd statistics daemon +After=network.target +Wants=network.target + +[Container] +Image=git.pyrocufflink.net/containerimages/collectd:latest +Volume=/etc/collectd.d:/etc/collectd.d:ro +Volume=/run:/run:rw +Tmpfs=/tmp +Network=host +SecurityLabelDisable=true +PodmanArgs=--privileged +PodmanArgs=--ipc=host +PodmanArgs=--uts=host +PodmanArgs=--pid=host +PodmanArgs=--cgroupns=host + +[Install] +WantedBy=multi-user.target diff --git a/collectd.yaml b/collectd.yaml index 8ed3177..4c3cbd6 100644 --- a/collectd.yaml +++ b/collectd.yaml @@ -1,22 +1,13 @@ variant: fcos version: 1.4.0 -ignition: - config: - merge: - - local: packages.yaml - storage: files: - - path: /etc/ignition/packages.d/collectd + - path: /etc/containers/systemd/collectd.container mode: 0644 contents: - inline: | - collectd - collectd-chrony - collectd-disk - collectd-sensors - collectd-write_prometheus + local: collectd.container + - path: /etc/collectd.d/df.conf mode: 0644 contents: @@ -27,6 +18,7 @@ storage: FSType overlay IgnoreSelected true + - path: /etc/collectd.d/plugins.conf mode: 0644 contents: @@ -50,8 +42,3 @@ storage: Port 9103 - -systemd: - units: - - name: collectd.service - enabled: true