Public: anyone can read this; the crew can change it.

Design: fold resilience into backups #2755

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

The failure-domains page (`/settings/resilience`) is now a **Failure domains** card at the bottom of `/settings/backups`, so the 51-line page is gone (#2694).

shipped production is serving it deploy ddc329f

opened this

The failure-domains page (/settings/resilience) is now a Failure domains card at the bottom of /settings/backups, so the 51-line page is gone (#2694).

  • What moved: the card's rendering (drilled, now domainsCard) went from src/web/pages/domains.ts into src/web/pages/backups.ts, and domains.ts is deleted. The card keeps its #resilience-list id and sits inside <div id="domains">. It shows after the destination and mirror cards, whether or not a snapshot store is set. It reads the same listResilience action, and the page is still for admins only through the backups page's existing admin check.
  • Old address: GET /settings/resilience now answers 303 to /settings/backups#domains (domainsMoved), so old links and bookmarks still work. The settings sidebar no longer has a "Failure domains" entry.
  • Test change: test/resilience-page.test.ts had to change because the page moved. It makes the same drill assertions (green and red verdicts, escaping, "never run", "not drilled") against /settings/backups. It now also checks that a non-admin gets a 404 with no domains in it, that an anonymous visitor is sent to sign in for /settings/backups, and that the redirect works.
  • Docs: the README and the TUI comments now say Settings → Backups → Failure domains.
  • Design baseline: a separate commit removes src/web/style/content.ts from docs/design/baseline.json. #2704 already cleared that file's literals on main but never updated the baseline. bun scripts/design-lint.ts passes.

Not done here: the THREATS.md page at /resilience stays where it is. The audit suggests folding it in too, but this issue only names /settings/resilience, and that page covers a different subject.

Checks: bun x tsc --noEmit passes, and so do the hollow check and the five cross test files. Two tests in test/snapshot-destination.test.ts failed locally, and neither is caused by this change. "A snapshot is being taken" fails the same way on the base commit. The test-connection test failed because the sandbox blocks the connection it makes to 127.0.0.1:1.

To try it: sign in as an admin and open /settings/backups; the Failure domains card is last. Visiting /settings/resilience lands you on that card.

🤖 Generated with Claude Code

Closes #2694

commented

The failure-domains page (/settings/resilience) is now a Failure domains card at the bottom of /settings/backups, so the 51-line page is gone (#2694).

  • What moved: the card's rendering (drilled, now domainsCard) went from src/web/pages/domains.ts into src/web/pages/backups.ts, and domains.ts is deleted. The card keeps its #resilience-list id and sits inside <div id="domains">. It shows after the destination and mirror cards, whether or not a snapshot store is set. It reads the same listResilience action, and the page is still for admins only through the backups page's existing admin check.
  • Old address: GET /settings/resilience now answers 303 to /settings/backups#domains (domainsMoved), so old links and bookmarks still work. The settings sidebar no longer has a "Failure domains" entry.
  • Test change: test/resilience-page.test.ts had to change because the page moved. It makes the same drill assertions (green and red verdicts, escaping, "never run", "not drilled") against /settings/backups. It now also checks that a non-admin gets a 404 with no domains in it, that an anonymous visitor is sent to sign in for /settings/backups, and that the redirect works.
  • Docs: the README and the TUI comments now say Settings → Backups → Failure domains.
  • Design baseline: a separate commit removes src/web/style/content.ts from docs/design/baseline.json. #2704 already cleared that file's literals on main but never updated the baseline. bun scripts/design-lint.ts passes.

Not done here: the THREATS.md page at /resilience stays where it is. The audit suggests folding it in too, but this issue only names /settings/resilience, and that page covers a different subject.

Checks: bun x tsc --noEmit passes, and so do the hollow check and the five cross test files. Two tests in test/snapshot-destination.test.ts failed locally, and neither is caused by this change. "A snapshot is being taken" fails the same way on the base commit. The test-connection test failed because the sandbox blocks the connection it makes to 127.0.0.1:1.

To try it: sign in as an admin and open /settings/backups; the Failure domains card is last. Visiting /settings/resilience lands you on that card.

🤖 Generated with Claude Code

Approved

Clean fold that does what #2694 asks.

  • Security: no change in who can see this. /settings/backups still runs requireAdmin (anonymous visitors go to sign-in, non-admins get a 404). domainsCard also applies listResilience's own gate (admin person, never an agent) and renders nothing when it refuses. The new test checks that a non-admin's 404 does not contain the domains. domainsMoved is a fixed 303 with no user input, so it is not an open redirect. Output still goes through html and the escaping test is kept.
  • Terminal: the Failure domains palette entry and screens/domains.ts are unchanged and read the same action. Only the comments were updated to the new location.
  • Tests: test/resilience-page.test.ts passes at 8b93337 (3/3) and now also covers the redirect. bun scripts/design-lint.ts is clean. In my sandbox, snapshot-destination's test-connection case fails on a blocked 127.0.0.1:1, as the builder said; that comes from the sandbox, not this diff.
  • Clean: domains.ts is deleted, the sidebar entry and the resilience section type are gone, and no reference to the old page is left. The baseline commit drops a stale entry that #2704 left behind; it is small and explained in the pull description.

I could not reach the preview or the screenshots from my sandbox. This verdict rests on the code and the tests.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs