mirror of https://github.com/Icinga/icinga2.git
parent
f8f89cef6d
commit
4b6abd9aa7
|
@ -3,7 +3,18 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
apply ScheduledDowntime "backup-downtime" to Service {
|
apply ScheduledDowntime "backup-downtime" to Service {
|
||||||
import "backup-downtime"
|
author = "icingaadmin"
|
||||||
|
comment = "Scheduled downtime for backup"
|
||||||
|
|
||||||
assign where host.name == "localhost" && service.name == "load"
|
ranges = {
|
||||||
|
monday = service.vars.backup_downtime
|
||||||
|
tuesday = service.vars.backup_downtime
|
||||||
|
wednesday = service.vars.backup_downtime
|
||||||
|
thursday = service.vars.backup_downtime
|
||||||
|
friday = service.vars.backup_downtime
|
||||||
|
saturday = service.vars.backup_downtime
|
||||||
|
sunday = service.vars.backup_downtime
|
||||||
|
}
|
||||||
|
|
||||||
|
assign where service.vars.backup_downtime != ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,4 +9,6 @@ object Service "load" {
|
||||||
host_name = "localhost"
|
host_name = "localhost"
|
||||||
check_command = "load"
|
check_command = "load"
|
||||||
vars.sla = "24x7"
|
vars.sla = "24x7"
|
||||||
|
|
||||||
|
vars.backup_downtime = "02:00-03:00"
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,21 +70,3 @@ template Notification "mail-service-notification" {
|
||||||
period = "24x7"
|
period = "24x7"
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Provides default settings for recurring backup downtime
|
|
||||||
*/
|
|
||||||
|
|
||||||
template ScheduledDowntime "backup-downtime" {
|
|
||||||
author = "icingaadmin"
|
|
||||||
comment = "Scheduled downtime for backup"
|
|
||||||
|
|
||||||
ranges = {
|
|
||||||
monday = "02:00-03:00"
|
|
||||||
tuesday = "02:00-03:00"
|
|
||||||
wednesday = "02:00-03:00"
|
|
||||||
thursday = "02:00-03:00"
|
|
||||||
friday = "02:00-03:00"
|
|
||||||
saturday = "02:00-03:00"
|
|
||||||
sunday = "02:00-03:00"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in New Issue