Web dashboard: multi-host agent launch + monitoring (paid control plane) #327
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
A web-based control-plane dashboard for bot-bottle: pick a host, launch an agent into an isolated bottle, and watch running agents — from a browser. This is the operator-facing surface for the paid control plane (per monetization-positioning: give away the sandbox, charge for the control plane). Cross-host launch + fleet visibility is exactly the "cross-run aggregation + central enforcement + identity/fleet = paid" line.
This is a design sketch to align on shape before a PRD.
Goals
http.server/socketserver), same discipline assupervise_server.py. Small amount of vanilla JS (fetch + polling) only where it earns its keep; no framework, no bundler, no npm.Non-goals (for the first cut)
./cli.py— it drives the same orchestrator, doesn't fork logic.Why served via stdlib / vanilla
bot_bottle/orchestrator/) already owns lifecycle/state/events; the dashboard is a thin read/command layer over it. A stdlib HTTP server + a handful of JSON endpoints is enough.supervise_server.py, which is already a stdlib-only HTTP+JSON server.Proposed shape
Layout (sidebar + main area)
Initial version scope
The first cut is intentionally minimal — home view only:
Endpoints (stdlib server, JSON)
GET /api/hosts— hosts + backend + reachability + running count.GET /api/agents— running/recent bottles with status (polled every ~2–3s).GET /api/agents/{slug}— detail: manifest summary, provenance, recent egress log tail.POST /api/agents— launch{host, bottle, prompt}→ orchestrator start.POST /api/agents/{slug}/stop— stop/teardown.GET /+/app.css+/app.jsserved from an embeddeddashboard/dir.All command endpoints go through the existing orchestrator (
lifecycle.py/runner.py/store.py/targeting.py) rather than re-implementing launch/stop.Account-scoped definitions (bottles, agents, env)
Today a bottle is a hand-written manifest under
~/.bot-bottle/bottles/, and agents can be shipped by repos (but bottles cannot — the$HOMEtrust boundary). The dashboard adds an account as the owning scope for these definitions, so an operator can author them once and reuse/launch them anywhere.manifest_bottle.py/manifest_schema.py): skills, env, git identity/remotes, egress routes. Validate with the existing loader (manifest_loader.py) so the UI can't produce a manifest the runtime would reject; unknown keys still die at load.manifest_agent.py) and compose bottles viaextends:(keep provider/runtime policy in a base likeclaude, overlay task bottles).~/.bot-bottle/bottles/(preserving the trust boundary: bottles still resolve from$HOME, the account store is a synced source, not a new load path the agent can reach).Env vars / secrets — custody, not just storage
This must not weaken the existing secret model: host secrets live in a sidecar, the agent dials
http://sidecar:9099/<path>, and the proxy injects the real token —printenvin the agent shows proxy URLs only. So env-var storage here is custody, not "hand the agent a.env":manifest_egress.py/ sidecar auth-injection semantics rather than inventing a second secret path.Additional endpoints
GET/POST/PUT/DELETE /api/bottles[/{name}]— CRUD account-scoped bottle definitions (validated through the manifest loader).GET/POST/PUT/DELETE /api/agents-def[/{name}]— CRUD account-scoped agent definitions. (Distinct from/api/agents, which is running instances.)GET /api/secrets— list secret names + metadata only (never values).PUT /api/secrets/{name}— set/rotate a secret value (write-only).DELETE /api/secrets/{name}— remove.Open questions
targeting.py/config.py, or a new hosts config? How are remote hosts reached (SSH? a remote backend agent)?bot-bottle-orchestratorbinary per the open/paid split, or adashboardmodule gated behind the paid build?~/.bot-bottle/bottles/at launch enough, or do we need explicit push/pull so a definition edited on one host is usable on another?Acceptance (v1 — home view only)
I think the dashboard for desktop should look like this:
Initial version will omit search, filtering, the ability to create new agents, logs, and all other views except the home view. Should be very basic.
(Also “home” menu button should be at the top of the menu, not second from bottom like depicted)
Updated the issue to reflect this — terminal and status are now side by side in the diagram, sidebar words are no longer truncated, and the photo is embedded above the layout sketch.
@didericis-claude we should probably rename the "status" window to "info"
Good call — updated throughout (diagram, descriptions, and acceptance criteria).