dashboard: point frontend at the /api/* backend routes
Phase 2 of the dashboard route consolidation. The backend now double-registers every bare top-level route (approve/deny/kill/restart/start/rebuild/destroy/ update-all/answer-question/cancel-question/purge-tombstone/matrix-account-login/ cancel-reminder/retry-reminder/request-spawn/op-send/meta-update/dashboard-stream/ dashboard-history) at an additional /api/<same> path. Switch every dashboard-pkg fetch / EventSource / form action to the /api/ form so "backend = /api/*" holds on the frontend side too. Bare paths still answer, so this is independently deployable; once it ships the backend can drop the bare registrations (phase 3). webhook/knowledge stays a distinct webhook prefix (forge-driven, no SPA caller). app.js's /rebuild,/start are the agent harness UI (different server) and are untouched. Part of #1846 (phase 2).
This commit is contained in:
parent
d3e3c4a41e
commit
905b38b6c7
9 changed files with 36 additions and 36 deletions
|
|
@ -240,7 +240,7 @@ import { createTabStrip } from '@hive/shared/tabs.js';
|
|||
if (buildRefreshTimer) clearTimeout(buildRefreshTimer);
|
||||
buildRefreshTimer = setTimeout(fetchBuild, 2000);
|
||||
};
|
||||
const es = openStream('/dashboard/stream');
|
||||
const es = openStream('/api/dashboard/stream');
|
||||
if (es) {
|
||||
es.onmessage = (e) => {
|
||||
let ev;
|
||||
|
|
|
|||
Loading…
Reference in a new issue