Skip to content

release/20260731 — 1 commit(s) | Dev - #21

Merged
cdrrazan merged 10 commits into
mainfrom
develop
Jul 31, 2026
Merged

release/20260731 — 1 commit(s) | Dev#21
cdrrazan merged 10 commits into
mainfrom
develop

Conversation

@cdrrazan

Copy link
Copy Markdown
Owner

🎉 Release day | By @cdrrazan

1 commit(s) develop → main. Merging deploy sthe fresh changes!.


🚀 Features

  • 5a9ef20 feat(web): real-time monitoring Dashboard + logo links home

Add a Dashboard page to the control panel — a live server-monitoring
view above Resources in the sidebar (below the logo).

- GET /dashboard renders charts in the shared shell (both sidebars),
  Page="metrics"; GET /api/metrics is the real-time JSON feed the page
  polls every 5s: aggregate CPU/memory/network, running/total, per-app
  metrics, host (RAM/disk/uptime/cores), docker disk+cache, edge/tunnel,
  incidents (open/resolved + 14-day buckets), and an accumulated
  time-series ring (metricSample, capped, in-memory like the sparkline
  trend). Read-only, so unguarded like GET /api/app.
- Charts are hand-rolled inline SVG (no external libs, CSP-safe): CPU /
  memory / network line charts over time, memory-by-app bars, utilization
  gauges (uptime / memory / disk), storage & cache tiles, a 14-day
  incidents bar chart, per-app uptime, and edge/host facts — plus a stat
  tile row. The page self-polls; refresh() early-returns on it so the
  whole-page swap can't wipe the charts.
- Sidebar gains a Dashboard nav item; "All apps" is active only on home.
- The logo is now an <a href="/"> (display:block) so clicking it goes home.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 31, 2026

Copy link
Copy Markdown

Deploying roost-gh with  Cloudflare Pages  Cloudflare Pages

Latest commit: 47337b7
Status: ✅  Deploy successful!
Preview URL: https://eccfe9c5.roost-gh.pages.dev
Branch Preview URL: https://develop.roost-gh.pages.dev

View logs

cdrrazan and others added 9 commits July 31, 2026 10:12
- Every chart box is a fixed 250px card (flex column); its body is a
  .dbody that scrolls when content overflows (long app lists no longer
  stretch the card).
- Charts fill the card body (chart/lc height:100%; daybars flex).
- Remove the "Edge & host" card (and its JS) for now.
- Un-nest the boxes: #dash is a plain section, not a .card, so the cards
  sit at page level instead of inside one big card; header becomes
  .dash-head, spacing via the section's flex gap.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Size the 8 cards to the available viewport instead of a fixed height.
layout() picks a column count from the width (4 / 2 / 1) and sets every
card's height to the space left below the grid divided by the row count,
via --cols / --ch CSS vars on the grid. Recomputed on load, after each
poll (tiles can shift the grid's top), and on resize (debounced), so all
rows fit on screen without the page scrolling — each card body still
scrolls internally when its content overflows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Cover the new control-panel Dashboard (sidebar → Dashboard, above
Resources) across README, docs/configuration, the site, and the
internal/web architecture note: real-time /api/metrics poll every 5s and
inline-SVG charts (CPU/memory/network over time, memory by app,
utilization gauges, storage & cache, 14-day incidents, per-app uptime),
plus the logo linking home.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the raw error screens visitors see when something is down with a
branded "temporarily offline" page, matched to who can still answer:

- App container down (Caddy up, upstream down -> 502/503): a (roost_maintenance)
  Caddyfile snippet each app site imports serves the generated error.html via
  handle_errors. Always on, no config. error.html is mounted into the caddy
  service by compose.

- Whole tunnel down (cloudflared/Docker/box off -> Cloudflare 1033): nothing on
  the host is reachable, so only the edge can answer. Opt-in
  tunnel.maintenance_page deploys a Cloudflare Worker (roost-maintenance, one
  "*.<zone>/*" route per routing suffix) that proxies through when healthy and
  substitutes the page only on an origin-connectivity failure
  (thrown fetch or 502/503/504/52x/530). Idempotent: an existing route on our
  pattern is repointed, never duplicated.

RenderErrorPage() is the single source of the page; the Worker embeds the same
bytes (JSON-encoded into a JS string literal), so both layers render an
identical self-contained page (no external assets, dark/light aware,
auto-retry 30s). State records the script+routes so uninstall removes exactly
what roost created (routes first, then script; failed routes kept for retry).

Custom Error Pages would be the native 1033 fix but Cloudflare gates the
1000_errors class to Enterprise; the Worker works on the free plan.

Two-dependency rule intact (stdlib only); no test touches real Docker/network
(worker client tested against httptest.Server).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Redesign the branded offline/maintenance page (served by Caddy on 502 and by
the edge Worker on 1033):

- Animated night "roost" scene as inline SVG: moon + craters, twinkling stars,
  a little bird perched on a wire, gently bobbing asleep with floating z's.
- roost wordmark + inline logo glyph; roost-themed copy ("gone to roost").
- Spinner + "wake it now" retry, footer credit (Rajan Bhattarai) and repo link.
- Full dark/light theming via CSS vars + color-mix.

Still fully self-contained: the only outbound references are the credit/repo
anchor links (navigated on click, never fetched to render), so it renders with
no origin reachable. Test now forbids externally *loaded* assets (src=, <link,
@import, cdn/fonts) rather than all URLs, and asserts the repo link is present.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Port the offline UI concept to the Fleet dashboard template: a standalone
offline.html served when a service is unreachable (proxy 502/503 or a downed
tunnel). Fleet-skinned (MD3 tokens, Google Sans, indigo) rather than roost's
palette: an animated moonlit-harbour scene (a sailboat at anchor, drifting
waves, twinkling stars), an "At anchor" badge, spinner, and auto-retry every
30s (honours prefers-reduced-motion). Linked from Components → Offline page;
CHANGELOG 1.7.0.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@cdrrazan
cdrrazan merged commit 235dc36 into main Jul 31, 2026
5 checks passed
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