Services: opt-in monitoring with a per-server watch list

A failed service now raises an alert (and counts in /metrics and the public API) only when the server is told to watch it, by name or pattern, or * for all. Failed services that are not watched still show on the Host health card with a Watch button. Replaces the ignore list.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
bobbanandClaude Sonnet 5.5 committed 2026-11-16 21:48:32 +01:00
1 parent 6e39430a1f
commit 06ac120a1d
19 files changed
+143 -121

No files matched your search

+1 -1
View File
@@ -109,7 +109,7 @@ describe("through the report, the alerts, the figures and the page", () => {
{ oidcSub: "admin", name: "Ada", role: "admin" },
{ oidcSub: "operator", name: "Olle", role: "operator" },
]);
const [s] = await db.insert(servers).values({ name: "elsa", apiTokenHash: hashToken("tok"), apiTokenPrefix: "t" }).returning();
const [s] = await db.insert(servers).values({ name: "elsa", apiTokenHash: hashToken("tok"), apiTokenPrefix: "t", thresholds: JSON.stringify({ watchServices: ["*"] }) }).returning();
id = s.id;
const a = express();
a.use("/api/agent/report", agentReportRouter);