bundles/icinga2: set some notification options for checks

This commit is contained in:
Franzi 2020-11-22 08:24:44 +01:00
parent b114ba3ff8
commit 4a57926577
Signed by: kunsi
GPG key ID: 12E3D2136B818350
10 changed files with 27 additions and 9 deletions

View file

@ -76,6 +76,7 @@ if node.has_bundle('sshmon'):
},
'ZFS MOUNTED VOLUMES': {
'command_on_monitored_host': 'sudo /usr/local/share/icinga/plugins/check_zfs_volumes',
'vars.notification.mail': True,
},
'ZFS OLD SNAPSHOTS': {
'command_on_monitored_host': 'sudo /usr/local/share/icinga/plugins/check_zfs_old_snapshots',
@ -147,10 +148,12 @@ def monitoring(metadata):
for poolname, pool_options in metadata.get('zfs/pools').items():
services['ZFS ZPOOL ONLINE {}'.format(poolname)] = {
'command_on_monitored_host': 'sudo /usr/local/share/icinga/plugins/check_zpool_online {}'.format(poolname),
'vars.notification.mail': True,
}
services['ZFS ZPOOL SPACE ' + poolname] = {
'command_on_monitored_host': 'sudo /usr/local/share/icinga/plugins/check_zpool_space {} 90'.format(poolname)
'command_on_monitored_host': 'sudo /usr/local/share/icinga/plugins/check_zpool_space {} 90'.format(poolname),
'vars.notification.mail': True,
}
return {