2021-09-13 19:26:31 +02:00
|
|
|
---
|
|
|
|
- name: download additional plugins
|
|
|
|
get_url:
|
|
|
|
url: "{{ item.src }}"
|
|
|
|
dest: "{{ munin_plugin_src_path }}{{ item.name }}"
|
|
|
|
mode: '0755'
|
|
|
|
loop: "{{ munin_node_plugins }}"
|
2021-09-24 10:11:54 +02:00
|
|
|
notify: restart munin-node
|
2021-10-15 12:38:56 +02:00
|
|
|
no_log: true
|
2022-02-18 20:34:43 +01:00
|
|
|
check_mode: no # damit werden auch im check-mode die Plugins heruntergeladen, sonst schlägt der nächste Task fehl
|
2021-09-13 19:26:31 +02:00
|
|
|
|
|
|
|
- name: enable additional plugins
|
|
|
|
file:
|
|
|
|
src: "{{ munin_plugin_src_path }}{{ item.name }}"
|
|
|
|
dest: "{{ munin_plugin_dest_path }}{{ item.name }}"
|
|
|
|
state: link
|
|
|
|
notify: restart munin-node
|
|
|
|
loop: "{{ munin_node_plugins }}"
|
2021-10-15 12:38:56 +02:00
|
|
|
no_log: true
|
2021-09-13 19:26:31 +02:00
|
|
|
|
|
|
|
- name: copy additional plugin-config
|
|
|
|
copy:
|
|
|
|
content: "{{ item.config }}"
|
|
|
|
dest: "{{ munin_plugin_conf_dest_path }}{{ item.name }}"
|
|
|
|
notify: restart munin-node
|
|
|
|
loop: "{{ munin_node_plugins }}"
|
|
|
|
when: item.config is defined
|
2021-10-15 12:38:56 +02:00
|
|
|
no_log: true
|
2021-09-13 19:26:31 +02:00
|
|
|
|
|
|
|
- name: Ensure munin-node is running.
|
|
|
|
service:
|
|
|
|
name: munin-node
|
|
|
|
state: started
|
|
|
|
enabled: yes
|