Manage `libs` plugin and state.

This commit is contained in:
Jeremy Gardais 2017-09-04 17:42:53 +02:00
parent fe1b22390f
commit 7f471b284f
6 changed files with 25 additions and 1 deletions

View File

@ -4,6 +4,7 @@
### Features
* Add the possibility to manage 'xymon' user's groups.
* Manage `mq` plugin and state.
* Manage `libs` plugin and state.
## v1.0

View File

@ -30,6 +30,9 @@ Manage Xymon (client) installation and configuration.
* **xymon_plug_mq_state**: The state of plugin `mq` [default: `true`].
* **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`].
* **xymon_plug_libs_path**: Configuration file for the `libs` plugin [default: `/etc/xymon/clientlaunch.d/libs.cfg`].
* **xymon_plug_libs_tpl**: Template used to generate the previous config file [default: `etc/xymon/clientlaunch.d/libs.cfg.j2`].
### OS Specific Variables
@ -57,6 +60,7 @@ This role will:
## Plugins
Some plugins and options can be managed with this role:
* libs: Check for running processes with upgraded libraries.
* mq: Check mail queue.
## Development

View File

@ -25,3 +25,6 @@ xymon_plug_manage: true
xymon_plug_mq_state: true
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
xymon_plug_libs_path: '/etc/xymon/clientlaunch.d/libs.cfg'
xymon_plug_libs_tpl: 'etc/xymon/clientlaunch.d/libs.cfg.j2'

View File

@ -53,4 +53,14 @@
mode: 0644
when: xymon_plug_manage
notify: restart xymon-client service
- name: PLUGIN libs
template:
src: '{{ xymon_plug_libs_tpl }}'
dest: '{{ xymon_plug_libs_path }}'
owner: root
group: root
mode: 0644
when: xymon_plug_manage
notify: restart xymon-client service
# }}}

View File

@ -0,0 +1,6 @@
[libs]
{{ '#DISABLED' if xymon_plug_libs_state else 'DISABLED' }}
ENVFILE /etc/xymon/xymonclient.cfg
CMD $XYMONCLIENTHOME/ext/libs
LOGFILE /var/log/xymon/xymonclient.log
INTERVAL 5m

View File

@ -1,5 +1,5 @@
[mq]
"{{ '#DISABLED' if xymon_plug_mq_state else 'DISABLED' }}"
{{ '#DISABLED' if xymon_plug_mq_state else 'DISABLED' }}
ENVFILE /etc/xymon/xymonclient.cfg
CMD $XYMONCLIENTHOME/ext/mq
LOGFILE /var/log/xymon/xymonclient.log