1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-02-13 19:52:06 +00:00
iiab/roles/munin/tasks/main.yml

30 lines
1.1 KiB
YAML

- assert:
that: munin_install is defined and munin_install is sameas true
success_msg: munin_install is defined and munin_install is sameas true
- assert:
that: munin_enabled is defined and munin_enabled | type_debug == 'bool'
success_msg: munin_enabled is defined and munin_enabled | type_debug == 'bool'
- name: Install Munin if 'munin_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml
when: munin_installed is undefined
- name: Enable or Disable Munin
include_tasks: enable-or-disable.yml
- name: Add 'munin' variable values to {{ iiab_ini_file }}
ini_file:
path: "{{ iiab_ini_file }}"
section: munin
option: "{{ item.option }}"
value: "{{ item.value | string }}"
with_items:
- option: name
value: Munin
- option: description
value: '"Munin is a networked resource monitoring tool that can help analyze resource trends and ''what just happened to kill our performance?'' problems."'
- option: installed
value: "{{ munin_install }}"
- option: enabled
value: "{{ munin_enabled }}"