bundles/icinga2: add automatic downtime for upgrade-and-reboot
All checks were successful
bundlewrap/pipeline/head This commit looks good

This commit is contained in:
Franzi 2020-11-22 13:28:14 +01:00
parent 3a56b0425c
commit 12ce8d8f6e
Signed by: kunsi
GPG key ID: 12E3D2136B818350
2 changed files with 43 additions and 0 deletions

View file

@ -17,6 +17,17 @@ SLA_INFO = {
'never': 'never',
}
DAYS_TO_STRING = [
'sunday',
'monday',
'tuesday',
'wednesday',
'thursday',
'friday',
'saturday',
'sunday',
]
directories = {
'/etc/icingaweb2': {
'group': 'icingaweb2',
@ -316,3 +327,17 @@ files['/etc/icinga2/conf.d/groups.conf'] = {
'svc_systemd:icinga2:restart',
},
}
files['/etc/icinga2/conf.d/downtimes.conf'] = {
'source': 'icinga2/downtimes.conf',
'content_type': 'mako',
'context': {
'monitored_nodes': monitored_nodes,
'days': DAYS_TO_STRING,
},
'needs': {
'pkg_apt:icinga2',
},
'triggers': {
'svc_systemd:icinga2:restart',
},
}