Fix gatus threshold for backups and add domains to service emails
This commit is contained in:
parent
a007ba8a33
commit
731647be9d
3 changed files with 22 additions and 15 deletions
|
|
@ -33,6 +33,13 @@ class FilterModule(object):
|
|||
|
||||
def vault_hosts_backup_to_gatus(self, hostvars):
|
||||
result = []
|
||||
backup_alerts = []
|
||||
for a in self.default_alerts:
|
||||
backup_alerts.append(dict(a, **{
|
||||
'failure-threshold': 1,
|
||||
'success-threshold': 1
|
||||
}))
|
||||
|
||||
for name, host_data in hostvars.items():
|
||||
if not host_data.get("host_backup_gatus_token"):
|
||||
continue
|
||||
|
|
@ -40,7 +47,7 @@ class FilterModule(object):
|
|||
"name": f"backup@{name}",
|
||||
"group": "8-backups",
|
||||
"token": host_data["host_backup_gatus_token"],
|
||||
"alerts": self.default_alerts,
|
||||
"alerts": backup_alerts,
|
||||
})
|
||||
return result
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue