Put alert rules, service levels, notifications and alert tickets on one Alert settings page, in four tabs

Old addresses (/alert-rules, /service-levels, /settings/notifications) lead to the right tab.
Notifications and Alert tickets stay administrator-only.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
bobbanandClaude Sonnet 5.5 committed 2026-11-03 20:38:15 +01:00
1 parent 07ce2b0305
commit 4269213275
40 files changed
+212 -188

No files matched your search

+6 -6
View File
@@ -70,7 +70,7 @@ It is for the readers written from documentation (see "Not verified" on each int
- **Container health:** on the 15-minute health pass the app also reads every container's state and status text and raises alerts for what is broken — see [Docker containers that are broken](docs/MONITORING.md#docker-containers-that-are-broken). A Docker host that Dockhand
cannot read (its Hawser agent is down) is an alert too, and its containers' alerts are held, not cleared. The Docker page shows each container's problem and has a **Leave alone** button.
- **Vulnerability scans:** every fifteen minutes the app also reads what Dockhand's scans have stored — `GET /api/vulnerabilities/count?env=` for each environment, and `GET /api/vulnerabilities?env=&severity=critical&limit=100` only where that count is above zero (needs the *images: view* permission). Nothing is scanned from here. **Critical** findings are a warning per Docker host — and so are **high** ones once a host has as many as a number you set (*Also warn when a Docker host has this many high vulnerabilities*, off by default) — (a setting turns the critical one off — see [MONITORING.md](docs/MONITORING.md#docker-containers-that-are-broken)); the Docker page lists them. **Written from Dockhand's source and OpenAPI file, not tried against a live Dockhand** — its published docs show the lists at the top level of the answer, its code puts the counts under `summary`; the reader follows the code and reads nothing it does not find as *unknown*.
- **Image age:** the same pass reads each Docker host's images and containers (`GET /api/images?env=`, `GET /api/containers?env=&all=true`) and keeps, for every image a *running* container uses, when it was built (Docker's own `Created`). Matched by the name the container gives (Docker Hub's `docker.io/library/` and a missing `:latest` are not a difference) or by id. With *Warn about running Docker images that were built more than … days ago* set (Settings → Notifications; **off by default**), a host with such images is a warning — whatever the scans of them said. The Docker vulnerabilities view shows each host's oldest running images either way. **Written from Dockhand's documented list (`Id`, `RepoTags`, `Created`), not tried against a live Dockhand**; an image whose date cannot be found is not judged.
- **Image age:** the same pass reads each Docker host's images and containers (`GET /api/images?env=`, `GET /api/containers?env=&all=true`) and keeps, for every image a *running* container uses, when it was built (Docker's own `Created`). Matched by the name the container gives (Docker Hub's `docker.io/library/` and a missing `:latest` are not a difference) or by id. With *Warn about running Docker images that were built more than … days ago* set (Alert settings → Notifications; **off by default**), a host with such images is a warning — whatever the scans of them said. The Docker vulnerabilities view shows each host's oldest running images either way. **Written from Dockhand's documented list (`Id`, `RepoTags`, `Created`), not tried against a live Dockhand**; an image whose date cannot be found is not judged.
### Uptime Kuma
@@ -169,7 +169,7 @@ That works on every Duplicati version, needs no login handshake and leaves nothi
backup **verification** — whether the data PBS actually stored still passes an integrity check, run separately by
PBS's verify jobs. This integration reads that directly from PBS (`verification.state` on each stored snapshot),
and a daily check (mirroring the Proxmox backup-failure check) sends a notification when a snapshot has failed
verification or a datastore couldn't be read at all — the "Notify on" section in Settings → Notifications has a
verification or a datastore couldn't be read at all — the "Notify on" section in Alert settings → Notifications has a
dedicated toggle for it, sharing the same daily reminder time as the other daily checks.
- **Not verified against a live instance** — built from PBS's own published API documentation (endpoints, the
`PBSAPIToken` header format, and the datastore/snapshot field names all cross-checked there), but nobody has run
@@ -220,7 +220,7 @@ That works on every Duplicati version, needs no login handshake and leaves nothi
a field looks wrong, tell us what happened and we'll adjust — this one has had less real-world exposure than
every other integration listed here.
**Optional: opening tickets for alerts** (Settings → Notifications → Alert tickets)
**Optional: opening tickets for alerts** (Alert settings → Alert tickets)
- **Config fields:** Ticket API address (optional), Ticket API key (optional, stored encrypted like the database
password), Allow self-signed certificate (ticket API). Leave them empty and the integration works as before.
@@ -229,7 +229,7 @@ That works on every Duplicati version, needs no login handshake and leaves nothi
app's requests come from (behind Docker or a reverse proxy that is the host's or proxy's address, not the
container's — check osTicket's log if it refuses) and tick **Can create tickets**. osTicket refuses a key from any
other address, which is the most common reason a test ticket fails.
- **What is sent:** one ticket per problem — name and email you set under Settings → Notifications → Alert tickets, a subject, the
- **What is sent:** one ticket per problem — name and email you set under Alert settings → Alert tickets, a subject, the
problem's text and a link back to this app, optionally a help topic and priority id — with `autorespond` off (the
"user" is this app, so an acknowledgement would only bounce) and osTicket's own staff alert on or off as you choose.
- **What the API can't do:** close, reopen, or comment on a ticket — osTicket's API has no such endpoint. Closing one is
@@ -263,7 +263,7 @@ osTicket's API cannot close a ticket, so this is the one place in the app that *
*Closed from Homelab Manager by <name>* with the reason you gave; and a **"closed" event** is recorded so the ticket's history reads like any other. Nothing else is touched, and nothing is ever deleted.
- **What it checks first:** that the tables and columns it writes to are there (written for **osTicket 1.14–1.18**); a different osTicket is refused with the list of what is missing, before anything is written. It closes only a ticket that is **open**, and only if its status is still what it was when it was read — a ticket somebody
else closes at the same moment is left as they left it. A ticket that was opened as part of a **summary ticket** (many problems at once) is not closed from here, because it covers other alerts.
- **Test closing** (Settings → Notifications → Alert tickets, next to *Send a test ticket*; administrators): signs in with the login, checks the tables and columns, and then **tries every write a close makes inside a transaction that is rolled back** — so a missing grant is found there and not on the first real ticket. Nothing stays (a counter or two
- **Test closing** (Alert settings → Alert tickets, next to *Send a test ticket*; administrators): signs in with the login, checks the tables and columns, and then **tries every write a close makes inside a transaction that is rolled back** — so a missing grant is found there and not on the first real ticket. Nothing stays (a counter or two
inside the database moves on).
- **Closing several alerts at once:** pick them on the Alerts page and choose *Close*; when some of them have a ticket that can be closed from here, the drawer offers *Also close N osTicket tickets* (with their numbers), and it is closed one ticket after another, each written on its alert's incident and in the audit log as above. One that cannot be closed does not stop the others: the alerts are closed all the same and the message says how many tickets were closed, were already closed, or could not be (with the first reason). Summary tickets and an osTicket with no closing login are counted and left open. **Undo opens the alerts again but cannot reopen the tickets** — the message says so.
- **What the alert shows:** the ticket badge says *(closed)* once it has been closed from here, and the Close drawer says so instead of offering it again. If the ticket cannot be closed, the alert is **still closed** and you are told why; the reason is also written on the incident and in the audit log (`alert_ticket/close_ticket`, `close_ticket_failed`).
@@ -305,7 +305,7 @@ osTicket's API cannot close a ticket, so this is the one place in the app that *
It all appears on **Network → Network devices**.
- A device is a **node in the dependency map**, like a server: the *connected through* link is made into a dependency by itself (an access point needs its switch, the switch needs the gateway), and you can write
others by hand (a server needs the switch it is plugged into).
- A device the controller has not seen online for longer than **Settings → Notifications → Alert when a network device is offline for** (10 minutes) is a critical **offline** alert about it. What needs it, and what
- A device the controller has not seen online for longer than **Alert settings → Notifications → Alert when a network device is offline for** (10 minutes) is a critical **offline** alert about it. What needs it, and what
it is connected through if that is down too, is folded under it, like a guest under its host. It can be silenced with a maintenance window, and has runbooks like any target.
- **Servers plugged in:** the controller's list of what is connected is matched to servers by IP address (exact, and only when one server has that address). A server is then *connected through* the switch or access point
it is on — a dependency made by itself, shown on the server's page and on the Connections map. A key or account that may not read clients costs only this; devices, networks and Wi-Fi names are unaffected.