Fix netdata diskspace plugin issue

This commit is contained in:
Wojciech Kozlowski 2023-10-29 15:56:35 +01:00
parent 34a250bd42
commit c2c25f214f
2 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,2 @@
[Service]
ReadOnlyDirectories=

View File

@ -14,6 +14,25 @@
when:
system_extra_netdata_install_sensors
- name: "create systemd override directory"
ansible.builtin.file:
path: "/etc/systemd/system/netdata.service.d"
state: "directory"
mode: 0755
- name: "create override configuration"
ansible.builtin.copy:
src: "./systemd/override.conf"
dest: "/etc/systemd/system/netdata.service.d/override.conf"
mode: 0644
register: system_extra_netdata_systemd_override
- name: "systemd user daemon reload"
ansible.builtin.systemd:
daemon_reload: true
when:
system_extra_netdata_systemd_override.changed
- name: "enable netdata"
ansible.builtin.systemd:
name: "netdata"
@ -51,6 +70,7 @@
(system_extra_netdata_install.changed or
(system_extra_netdata_lm_sensors_install is defined and
system_extra_netdata_lm_sensors_install.changed) or
system_extra_netdata_systemd_override.changed or
system_extra_netdata_netdata_conf.changed or
system_extra_netdata_stream_conf.changed or
system_extra_netdata_health_conf.changed) and