feat(dashboard): self-hosted coordinator dashboard at GET / #3

Merged
pyr0ball merged 1 commit from feature/orch-dashboard into main 2026-03-31 18:59:47 -07:00
Owner

Summary

  • Adds dashboard.html served by the coordinator at GET / — node-centric layout matching the brainstorm mockup Option A
  • GPU cards per node: VRAM fill bar (cyan→amber→red by utilisation), used/total GB, status label (idle/busy/saturated), VRAM sparkline (last 20 samples via inline SVG createElementNS)
  • Active leases table: service, node/GPU, VRAM granted, priority, TTL countdown + progress bar
  • Service health pill: coordinator up/down
  • Auto-refresh every 5 seconds via fetch() against the coordinator's own JSON API
  • All dynamic content (node IDs, service names, GPU names) set via textContent / createElementNS — no innerHTML with user-sourced strings
  • HTML read at import time from package path — zero additional dependencies, no build step

Test plan

  • conda run -n cf pytest tests/test_resources/test_coordinator_app.py -v — 8/8 pass
  • Start cf-orch coordinator: cf-orch start → visit http://localhost:7700/
  • GPU cards populate when an agent registers a node
  • Lease row appears/disappears as leases are granted/released
  • Error banner shows when coordinator is unreachable
## Summary - Adds `dashboard.html` served by the coordinator at `GET /` — node-centric layout matching the brainstorm mockup Option A - GPU cards per node: VRAM fill bar (cyan→amber→red by utilisation), used/total GB, status label (idle/busy/saturated), VRAM sparkline (last 20 samples via inline SVG `createElementNS`) - Active leases table: service, node/GPU, VRAM granted, priority, TTL countdown + progress bar - Service health pill: coordinator up/down - Auto-refresh every 5 seconds via `fetch()` against the coordinator's own JSON API - All dynamic content (node IDs, service names, GPU names) set via `textContent` / `createElementNS` — no `innerHTML` with user-sourced strings - HTML read at import time from package path — zero additional dependencies, no build step ## Test plan - [ ] `conda run -n cf pytest tests/test_resources/test_coordinator_app.py -v` — 8/8 pass - [ ] Start cf-orch coordinator: `cf-orch start` → visit `http://localhost:7700/` - [ ] GPU cards populate when an agent registers a node - [ ] Lease row appears/disappears as leases are granted/released - [ ] Error banner shows when coordinator is unreachable
pyr0ball added 1 commit 2026-03-31 18:57:50 -07:00
- dashboard.html: node-centric layout — GPU cards with VRAM bars and
  sparklines, active leases table with TTL progress bars, service health
  pill, auto-refreshes every 5s via fetch() against the local JSON API
- All dynamic content set via DOM textContent / createElementNS — no
  innerHTML with user-sourced strings
- coordinator/app.py: serves dashboard.html at GET / (HTMLResponse,
  excluded from OpenAPI schema); HTML read at import time from package dir
- test_dashboard_serves_html: verifies 200, content-type text/html,
  and key route markers present
pyr0ball merged commit 4596aad290 into main 2026-03-31 18:59:47 -07:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Circuit-Forge/circuitforge-core#3
No description provided.