Watch
0
0
Fork
You've already forked hyperhive
0

drop the sqlite event log nothing reads, and the comments naming routes that are gone

This commit is contained in:
iris 2026-11-16 04:40:22 +01:00 • committed by mara
commit cbda9c162f

View file

@ -1,13 +1,12 @@
//! Per-container HTTP UI. SPA shape: `GET /` returns a static shell;
//! `GET /static/*` serves CSS + JS; `GET /api/state` returns the page
//! state as JSON; the JS app renders. Live events stream on
//! `/events/stream`. Action POSTs return either a
//! 303 Redirect (for browsers that submit the form normally) or just
//! 200 OK — the JS app re-fetches `/api/state` afterwards.
//! Per-container HTTP server: the stats and screen pages (`GET /stats`,
//! `GET /screen`, `GET /static/*`), `GET /` redirecting to `/stats`, the small
//! JSON the dashboard card and those pages read (`/api/state`,
//! `/api/dashboard-state`, `/api/stats`) and the live event stream
//! `/events/stream`.
//!
//! Handlers are split by concern into the submodules below; this file owns the
//! shared [`AppState`], the listener + router wiring in [`serve`], and a couple
//! of small shared helpers ([`error_response`], [`SOCKET_FETCH_TIMEOUT`]).
//! shared [`AppState`], the listener + router wiring in [`serve`], and the
//! claude-signalling helpers the cancel command and the login watch share.
mod auth;
pub(crate) use auth::force_logout;
@ -230,8 +229,8 @@ fn read_gui_vnc_port() -> Option<u16> {
std::env::var("HIVE_GUI_VNC_PORT").ok()?.parse().ok()
}
/// Outcome of [`sigint_claude`] — shared by `/api/cancel` and `/api/logout`
/// so both can render the same three cases.
/// Outcome of [`sigint_claude`] — shared by the cancel command and the login watch's
/// logout so both can render the same three cases.
enum SigintOutcome {
/// The tracked pid was signalled.
Signalled,