Skip to content

fix(docker): redirect /monitor to the dashboard UI (#2091, point 7) - #2157

Merged
ntohidi merged 1 commit into
developfrom
fix/monitor-dashboard-redirect
Aug 20, 2026
Merged

fix(docker): redirect /monitor to the dashboard UI (#2091, point 7)#2157
ntohidi merged 1 commit into
developfrom
fix/monitor-dashboard-redirect

Conversation

@ntohidi

@ntohidi ntohidi commented Aug 20, 2026

Copy link
Copy Markdown
Collaborator

Follow-up to #2094, which closed the / half of point 7 in #2091. This closes the /monitor half.

Problem

Pre-0.9 docs pointed at /monitor for the dashboard. The UI actually lives at /dashboard (server.py:276); /monitor is the monitoring API prefix (monitor_routes.py:12) with no page of its own. A browser hitting the documented URL got a bare {"detail": "Authentication required"} and no pointer to the real UI.

Change

  • GET /monitor → 307 /dashboard, and "/monitor" added to the auth gate's exact-match public_paths.
  • /monitor/* stays gated. Making the prefix public would expose request logs, browser state, /monitor/ws, and the destructive admin actions (actions/cleanup, actions/kill_browser, stats/reset) with no credential.
  • Self-hosting doc note updated to describe the redirect.

Tests

test_legacy_compat.py: the redirect, a parametrized gate check over 8 /monitor/* routes, and a websocket gate check. The pre-existing placeholder (which accepted 401 or a redirect) is now tightened to require the redirect.

Mutation-checked both ways:

  • add /monitor to _UI_PREFIXES (the unsafe fix) → 9 failures, incl. the websocket test
  • drop /monitor from public_paths → redirect test fails

Full docker security suite: 319 passed, 1 xfailed.

…t 7)

Pre-0.9 docs pointed at /monitor for the dashboard, which now lives at
/dashboard. /monitor is the monitoring API prefix with no page of its own,
so a browser landed on a bare 401 with no pointer to the real UI.

Redirect the exact path /monitor -> /dashboard and allow it in the auth
gate's exact-match public_paths. The /monitor/* API routes - including
/monitor/ws and the destructive admin actions - stay gated; making the
prefix public would expose them unauthenticated.

Tests pin both halves and were mutation-checked: widening the gate to the
/monitor prefix fails the gated-route and websocket tests, and dropping
/monitor from public_paths fails the redirect test.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@ntohidi
ntohidi merged commit 5b2e86f into develop Aug 20, 2026
3 checks passed
@ntohidi
ntohidi deleted the fix/monitor-dashboard-redirect branch August 20, 2026 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant