diff --git a/CHANGELOG.md b/CHANGELOG.md index 3cd720a..8b9047c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,9 @@ +## v1.X + +## Enhancements +* Add possibility to install `mq` dependancies. + ## v1.0.1 ### Minor Features diff --git a/README.md b/README.md index 532939c..bc62668 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,7 @@ Manage Xymon (client) installation and configuration. * **xymon_srv_list** : The list of Xymon servers (you must give an hostname, IP,… reachable from any clients) [defaults : `monitoring.{{ ansible_domain }}`]. * **xymon_plug_manage** : If this role should manage plugins configuration [default : `true`]. * **xymon_plug_mq_state** : The state of plugin `mq` [default : `true`]. +* **xymon_plug_mq_package** : The packages to install to provide `mq` plugin [default : `[ 'libtimedate-perl' ]`]. * **xymon_plug_mq_path** : Configuration file for the `mq` plugin [default : `/etc/xymon/clientlaunch.d/mq.cfg`]. * **xymon_plug_mq_tpl** : Template used to generate the previous config file [default : `etc/xymon/clientlaunch.d/mq.cfg.j2`]. * **xymon_plug_libs_state** : The state of plugin `libs` [default : `true`]. diff --git a/defaults/main.yml b/defaults/main.yml index e581e77..6da7a60 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -23,6 +23,7 @@ xymon_srv_list: "monitoring.{{ ansible_domain }}" # plugins xymon_plug_manage: true xymon_plug_mq_state: true +xymon_plug_mq_package: [ 'libtimedate-perl' ] xymon_plug_mq_path: '/etc/xymon/clientlaunch.d/mq.cfg' xymon_plug_mq_tpl: 'etc/xymon/clientlaunch.d/mq.cfg.j2' xymon_plug_libs_state: true diff --git a/tasks/main.yml b/tasks/main.yml index beb097f..11eea73 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -44,6 +44,15 @@ # }}} # plugins {{{ +- name: PLUGIN mq packages + package: + name: '{{ item }}' + state: '{{ "present" if xymon_plug_mq_state else "absent" }}' + with_items: + - '{{ xymon_plug_mq_package }}' + when: xymon_plug_manage + notify: restart xymon-client service + - name: PLUGIN mq template: src: '{{ xymon_plug_mq_tpl }}'