Repository navigation
Description
Problem
The member home page shows a 7-day uptime strip, and members can get an "outage" notice. Both come from an optional Prometheus integration: an admin enters a Prometheus URL and a PromQL query (in practice, the Gatus uptime metrics), and the app reads 168 hourly up/down points from it. The code never refers to Gatus by name. It only stores a Prometheus row with name, url and query.
We don't want to keep this. It adds a setup-wizard step, an admin integration, a database model and a home-page section, and the uptime display isn't needed.
Proposal
Remove the Prometheus status integration from end to end: the setup step, the admin settings entry, the stored config, the status action, the uptime strip and the outage notice.
Out of scope, keep as is: the app's own Prometheus exporter at /api/metrics (app/api/metrics/route.ts, lib/observability/metrics.ts, lib/observability/prometheus-text.ts, METRICS_TOKEN). It's unrelated to the uptime feature.
Scope
Status data and UI
actions/prometheus-status.tsand__tests__/actions/prometheus-status.test.tscomponents/ui/uptime-strip.tsx,components/ui/__tests__/uptime-strip.test.tsx,lib/ui/uptime.tscomponents/dashboard/home-page.tsx: remove<UptimeStrip>and update the layout JSDoclib/member/home-data.ts(+ test): removeuptime/getPrometheusStatus()lib/member/notice.ts(+ test): remove the Prometheus-driven outage notice
Integration plumbing
lib/connections/prometheus.ts(+ test),lib/validations/prometheus.tslib/services/descriptors.ts: remove theprometheusServiceKindand its descriptor. Then follow the type errors throughlib/services/service-save.ts,lib/settings/{connection-health,connection-status,test-service,audit-meta}.ts,lib/connections/http.ts,lib/ui/icons.ts,actions/admin/admin-servers.ts,lib/data/admin-settings.tsandapp/admin/settings/page.tsxcomponents/admin/settings/sections/other-integrations-section.tsx,components/admin/settings/server-form.tsx,hooks/admin/use-server-form.ts: remove the Prometheus option and the query field
Setup wizard
types/setup.ts: remove theprometheusstep andPrometheusDefaultsactions/setup.ts,lib/setup/wizard-data.ts,lib/setup/dev-defaults.ts(theDEV_PROMETHEUS_*vars), andcomponents/setup/setup-wizard/*(setup-wizard.tsx,service-connection-form.tsx,setup-step-frame.tsx,use-setup-service-form.ts)- Check
prisma/migrations/20270117000010_p1024_setup_step_idsandprisma/__tests__/setup-step-ids.pg.test.ts: existing installs may haveprometheusrecorded as a completed or skipped step, and the wizard must still handle that
Database
- Drop
model Prometheusfromprisma/schema.prismawith a new migration (prisma migrate dev --create-only --name drop_prometheus_status). Don't edit20251208000000_add_prometheus.
Env and docs
lib/env.ts: rewordSKIP_CONNECTION_TESTS("skips live Plex and Prometheus checks") to just Plex, then runnpm run env:docsto regeneratedocs/environment.mdandexample.envREADME.md(setup wizard paragraph),docs/deployment.md,docs/operations.md,docs/privacy.md,CLAUDE.md: remove references to the uptime or status integration, but keep the/api/metricsdocsCHANGELOG.md: add a line under Unreleased. The Changelog check requires it for the migration. Add an Upgrade note that the stored Prometheus status config is dropped.
Tests
- Update the affected suites:
__tests__/actions/setup.test.ts,__tests__/security/setup-actions-security.test.ts,actions/__tests__/{admin-servers,admin-settings-secret-hiding,test-connection}.test.ts,components/admin/settings/__tests__/server-form.test.tsx, the setup-wizard component tests,lib/settings/__tests__/*,lib/ui/__tests__/icons.test.ts,lib/security/__tests__/config-diff.test.ts,types/__tests__/setup-steps.test.ts,__tests__/app/home-page.test.tsx - E2E:
e2e/setup-wizard.spec.tsande2e/helpers/seed-fixtures.ts - Visual baselines for the home page will change, so refresh them through the Visual Baselines workflow
- Coverage floors may drop slightly once these files are deleted, so check
jest.coverage-thresholds.json
Acceptance criteria
- The home page shows no uptime strip, and no outage notice comes from Prometheus
- Prometheus no longer appears in the setup wizard or in Admin, Settings, Other integrations
- The
Prometheustable is dropped by a new migration, and an existing install upgrades cleanly, including one whose setup progress recorded theprometheusstep -
/api/metricsstill works exactly as before - Lint, typecheck, knip, design check, unit, integration and E2E all pass
Activity