From c983238f246f150968da1f8f88aced85d1b9e02b Mon Sep 17 00:00:00 2001 From: "Dustin C. Hatch" Date: Tue, 28 Jun 2022 09:42:22 -0500 Subject: [PATCH] r/collectd: Manage collectd.d directory The `/etc/collectd.d` directory is created by the RPM package on machines running a Red Hat-based Linux distribution, but it may not always be present on other machines. --- roles/collectd/tasks/main.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/roles/collectd/tasks/main.yml b/roles/collectd/tasks/main.yml index cf569de..081169a 100644 --- a/roles/collectd/tasks/main.yml +++ b/roles/collectd/tasks/main.yml @@ -23,6 +23,14 @@ tags: - collectd-config +- name: ensure collectd config drop-in directory exists + file: + path: /etc/collectd.d + mode: u=rwx,go=rx + state: directory + tags: + - collectd-config + - name: ensure collectd directory exists file: path: /etc/collectd