feat(web): console pages for monitors, incidents and notification channels

The dashboard lists monitors with status, latency and 24-hour uptime
bars rendered as SVG on the server; monitor pages add 90-day uptime,
latency and recent checks; an editor shows the settings of the selected
check type.

Closes #17
Closes #19

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017GpWAskjmYtZpuQ5JwYTX3
This commit is contained in:
Sebastian UnterschützandClaude Opus 5.5 committed 2026-11-22 01:50:04 +01:00
1 parent 9a050ea712
commit b831478143
18 files changed
+4268 -323

No files matched your search

+18
View File
@@ -145,6 +145,24 @@ func TestEveryMailEventHasTexts(t *testing.T) {
}
}
// Templates build these IDs from a prefix and a value.
func TestDynamicFamilies(t *testing.T) {
en := catalogKeys(t)["en"]
families := map[string][]string{
"status.": {"up", "degraded", "down", "unknown", "paused"},
"monitors.type_": {"http", "tcp", "tls", "dns", "icmp"},
"channels.type_": {"webhook", "email"},
"agents.kind_": {"checker", "statuspage"},
}
for prefix, values := range families {
for _, v := range values {
if !en[prefix+v] {
t.Errorf("en.json is missing %q", prefix+v)
}
}
}
}
// The language switcher builds "lang.<code>" dynamically.
func TestEveryLanguageHasAName(t *testing.T) {
c, err := Load()
+58
View File
@@ -29,6 +29,20 @@
"auth.sso.heading": "Single Sign-on",
"auth.sso.org_placeholder": "Kurzname der Organisation",
"auth.sso.submit": "Weiter",
"channels.create": "Kanal anlegen",
"channels.delete_confirm": "Diesen Kanal löschen?",
"channels.intro": "Jeder aktive Kanal wird benachrichtigt, wenn ein Monitor in allen seinen Regionen ausfällt und wenn er sich erholt.",
"channels.language": "Sprache",
"channels.new_email": "Neuer E-Mail-Kanal",
"channels.new_webhook": "Neuer Webhook",
"channels.secret_now": "Signatur-Secret: Prüfe damit den Header X-Uptimesebi-Signature. Es wird nicht erneut angezeigt.",
"channels.test": "Test senden",
"channels.test_ok": "Testbenachrichtigung zugestellt.",
"channels.title": "Benachrichtigungen",
"channels.to": "Empfänger",
"channels.type_email": "E-Mail",
"channels.type_webhook": "Webhook",
"channels.url": "Webhook-URL",
"common.no": "nein",
"common.save": "Speichern",
"common.yes": "ja",
@@ -124,6 +138,10 @@
"error.totp_setup_expired": "Einrichtung abgelaufen, bitte neu starten.",
"error.unauthenticated": "Anmeldung erforderlich.",
"error.unsupported_locale": "Sprache wird nicht unterstützt.",
"incidents.none": "Bisher keine Incidents.",
"incidents.ongoing": "laufend",
"incidents.resolved": "behoben",
"incidents.title": "Incidents",
"invite.accept": "Einladung annehmen",
"invite.create_account": "Konto anlegen und beitreten",
"invite.sign_in": "Zum Annehmen anmelden",
@@ -145,6 +163,41 @@
"members.roles": "Rollen",
"members.title": "Mitglieder",
"members.unassign": "Rolle entfernen",
"monitors.confirmations": "Fehlschläge bis zum Alarm",
"monitors.confirmations_hint": "Aufeinanderfolgende Fehlschläge pro Region. Alarm gibt es erst, wenn alle gewählten Regionen ausfallen.",
"monitors.delete": "Monitor löschen",
"monitors.delete_confirm": "Diesen Monitor samt Verlauf löschen?",
"monitors.dns_expect": "Erwartete Antwort (optional)",
"monitors.dns_record": "Record-Typ",
"monitors.dns_resolver": "Resolver (host:port, optional)",
"monitors.edit": "Monitor bearbeiten",
"monitors.expect_status": "Erwarteter Status (z. B. 2xx, 301)",
"monitors.follow_redirects": "Weiterleitungen folgen",
"monitors.interval": "Intervall (Sekunden)",
"monitors.interval_hint": "Mindestens {{.Min}} Sekunden.",
"monitors.keyword": "Keyword in der Antwort",
"monitors.keyword_absent": "Fehler, wenn das Keyword vorkommt",
"monitors.last_24h": "letzte 24 Stunden",
"monitors.last_90d": "Letzte 90 Tage",
"monitors.latency_24h": "Latenz, letzte 24 Stunden",
"monitors.method": "Methode",
"monitors.new": "Neuer Monitor",
"monitors.recent": "Letzte Checks",
"monitors.regions": "Regionen",
"monitors.regions_hint": "Geprüft von einem zufälligen Checker jeder gewählten Region. Deine eigenen Regionen stehen oben.",
"monitors.target": "Ziel",
"monitors.target_hint": "URL für HTTP, host:port für TCP und TLS, Hostname für DNS und ICMP.",
"monitors.timeout": "Timeout (ms)",
"monitors.tls_min_days": "Mindestens Tage bis Ablauf",
"monitors.tls_server_name": "Servername (optional)",
"monitors.type": "Check-Typ",
"monitors.type_dns": "DNS",
"monitors.type_http": "HTTP(S)",
"monitors.type_icmp": "Ping (ICMP)",
"monitors.type_tcp": "TCP-Port",
"monitors.type_tls": "TLS-Zertifikat",
"monitors.uptime_chart": "Uptime pro Zeitraum",
"monitors.verify_tls": "TLS-Zertifikat prüfen",
"org.policy": "Anmelderichtlinie",
"org.require_sso": "SSO verlangen",
"org.require_sso_hint": "Mitglieder müssen sich über den Identity Provider dieser Organisation anmelden. Der Owner kann weiterhin ein Passwort nutzen, damit ein defekter IdP euch nicht aussperrt.",
@@ -231,6 +284,11 @@
"sso.settings.login_url": "Anmelde-URL",
"sso.settings.redirect_url": "Redirect-URL",
"sso.settings.title": "Single Sign-on",
"status.degraded": "in einzelnen Regionen gestört",
"status.down": "ausgefallen",
"status.paused": "pausiert",
"status.unknown": "keine Daten",
"status.up": "erreichbar",
"tokens.copy_now": "Kopiere den Token jetzt. Er wird nicht erneut angezeigt.",
"tokens.create": "Token erstellen",
"tokens.created": "Erstellt",
+58
View File
@@ -29,6 +29,20 @@
"auth.sso.heading": "Single sign-on",
"auth.sso.org_placeholder": "Organization short name",
"auth.sso.submit": "Continue",
"channels.create": "Create channel",
"channels.delete_confirm": "Delete this channel?",
"channels.intro": "Every enabled channel is notified when a monitor goes down in all of its regions and when it recovers.",
"channels.language": "Language",
"channels.new_email": "New email channel",
"channels.new_webhook": "New webhook",
"channels.secret_now": "Signing secret: verify the X-Uptimesebi-Signature header with it. It will not be shown again.",
"channels.test": "Send test",
"channels.test_ok": "Test notification delivered.",
"channels.title": "Notifications",
"channels.to": "Recipients",
"channels.type_email": "Email",
"channels.type_webhook": "Webhook",
"channels.url": "Webhook URL",
"common.no": "no",
"common.save": "Save",
"common.yes": "yes",
@@ -124,6 +138,10 @@
"error.totp_setup_expired": "Setup expired, please start again.",
"error.unauthenticated": "Authentication required.",
"error.unsupported_locale": "Unsupported language.",
"incidents.none": "No incidents so far.",
"incidents.ongoing": "ongoing",
"incidents.resolved": "resolved",
"incidents.title": "Incidents",
"invite.accept": "Accept invitation",
"invite.create_account": "Create account and join",
"invite.sign_in": "Sign in to accept",
@@ -145,6 +163,41 @@
"members.roles": "Roles",
"members.title": "Members",
"members.unassign": "Remove role",
"monitors.confirmations": "Failures before alerting",
"monitors.confirmations_hint": "Consecutive failures per region. An alert needs every selected region to fail.",
"monitors.delete": "Delete monitor",
"monitors.delete_confirm": "Delete this monitor and its history?",
"monitors.dns_expect": "Expected answer (optional)",
"monitors.dns_record": "Record type",
"monitors.dns_resolver": "Resolver (host:port, optional)",
"monitors.edit": "Edit monitor",
"monitors.expect_status": "Expected status (e.g. 2xx, 301)",
"monitors.follow_redirects": "Follow redirects",
"monitors.interval": "Interval (seconds)",
"monitors.interval_hint": "At least {{.Min}} seconds.",
"monitors.keyword": "Keyword in response",
"monitors.keyword_absent": "Fail if the keyword is present",
"monitors.last_24h": "last 24 hours",
"monitors.last_90d": "Last 90 days",
"monitors.latency_24h": "Latency, last 24 hours",
"monitors.method": "Method",
"monitors.new": "New monitor",
"monitors.recent": "Recent checks",
"monitors.regions": "Regions",
"monitors.regions_hint": "Checked from a random checker in each selected region. Your own regions are listed first.",
"monitors.target": "Target",
"monitors.target_hint": "URL for HTTP, host:port for TCP and TLS, host name for DNS and ICMP.",
"monitors.timeout": "Timeout (ms)",
"monitors.tls_min_days": "Minimum days until expiry",
"monitors.tls_server_name": "Server name (optional)",
"monitors.type": "Check type",
"monitors.type_dns": "DNS",
"monitors.type_http": "HTTP(S)",
"monitors.type_icmp": "Ping (ICMP)",
"monitors.type_tcp": "TCP port",
"monitors.type_tls": "TLS certificate",
"monitors.uptime_chart": "Uptime per period",
"monitors.verify_tls": "Verify TLS certificate",
"org.policy": "Sign-in policy",
"org.require_sso": "Require SSO",
"org.require_sso_hint": "Members must sign in through this organization's identity provider. The owner can still use a password so a broken IdP cannot lock you out.",
@@ -231,6 +284,11 @@
"sso.settings.login_url": "Sign-in URL",
"sso.settings.redirect_url": "Redirect URL",
"sso.settings.title": "Single sign-on",
"status.degraded": "failing in some regions",
"status.down": "down",
"status.paused": "paused",
"status.unknown": "no data",
"status.up": "up",
"tokens.copy_now": "Copy the token now. It will not be shown again.",
"tokens.create": "Create token",
"tokens.created": "Created",