Thorough cleanup after a full investigation of "so many things are wrong".
DEPLOYMENT — the "This deployment is temporarily paused" ghost. The canonical
host already moved to fleetcrown.orangecat.ch (Hetzner); the message came from
leftover references to the paused fleetcrown.vercel.app deployment:
- vercel.json: drop the `alias: ["fleetcrown.vercel.app"]` (the paused domain).
- scripts/fleet: install-cli POSTs to fleetcrown.orangecat.ch, not the dead URL.
- package.json: `ship` just pushes (the pre-push hook deploys to Hetzner);
replace `wait:vercel` with `deploy` → scripts/deploy-hetzner.sh.
- delete scripts/wait-for-vercel.sh and orphaned desktop/.vercel/.
- repoint stale Vercel URLs in scripts/db/*.md and the local VAPID_SUBJECT.
(Fleet Runner already targets orangecat.ch in source — the user's "paused"
view is a stale installed build; the current v0.8.0 build/.deb is in desktop/dist.)
ICON — the browser-tab icon was blank/wrong:
- public/icon.svg drew the spiral at ~23% of the canvas with 0.7/0.95 opacity,
so it vanished at 16px. Rescaled to fill ~62% at full contrast (shape
unchanged, matches BrandMark.tsx).
- delete the stale src/app/favicon.ico (still the Next.js starter triangle);
metadata already declares /icon.svg, so browsers now show the brand mark.
CONTROL honesty:
- Autopilot badge no longer shows a pulsing "Building" on every autopilot-on
project (the default), which made idle projects look actively worked. It's now
a static "Auto"/"Paused" policy chip; the pulse is reserved for real `working`.
- /activity stats (promptsSent/runsStarted) now come from real count(*)
aggregates instead of the 200-capped row arrays (showed "200" when the true
30-day count was 277).
- "Previous automated run" shows a crashed `running` row (no terminal write,
>30min old) as "interrupted" instead of a live-looking "running" tag.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Same job, one more source. Now the toolkit handles:
- FleetCrown out of Neon (`dump-from-neon.sh`)
- OrangeCat out of Supabase (`dump-from-supabase.sh`)
- Both consolidated onto one self-hosted Postgres box
scripts/db/dump-from-supabase.sh
Mirrors dump-from-neon.sh's interface. Supabase-specific guards:
- Refuses pooler URLs (port 6543 / pooler.supabase.com) because
pg_dump fails midway through transaction-pooled connections.
- Defaults to --schema=public only. Supabase's auth/storage/realtime/
extensions schemas would create dangling-role FK errors on a vanilla
Postgres target. FULL_DUMP=1 dumps everything when self-hosting
gotrue too (bigger project for another day).
- Same .sql + .manifest.txt output shape as the Neon script;
restore-to-target.sh accepts either without modification.
scripts/db/BOTH_PRODUCTS_ONE_HOST.md
Layers two databases (`fleetcrown`, `orangecat`) on a single Postgres
instance with separate roles and per-role pg_hba.conf lines. Covers:
- role + database setup
- pg_hba rules: each role authenticates only to its own DB
- migration sequence: FleetCrown first (it's broken), OrangeCat
second (still functional on Supabase)
- auth-stays-on-Supabase recommendation for OrangeCat (cheap, no
gotrue self-host needed at this scale)
- shared backup cron with off-box rsync mirror
- PgBouncer add-on for when connection count balloons
- explicit "when to split the box" thresholds (sustained 70% CPU,
<95% cache hit ratio, p95 latency >50ms)
scripts/db/README.md
Updated header + file table to mention both products. Migration
cookbook now has separate Step 1 entries for Neon vs Supabase and
points at BOTH_PRODUCTS_ONE_HOST.md for the dual-product path.
Capacity sanity for the curious: a Hetzner CX22 (€4.51/mo, 2 vCPU, 4 GB
RAM, 40 GB SSD) is over-provisioned by ~3 orders of magnitude for both
products at today's scale (single-user each). Upgrade in-place to CX32
when sustained CPU exceeds 70% — that's many months out.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Grab-and-place migration kit so we can move off Neon (which capped our
data transfer earlier today) on ~30 min notice when the quota resets or
we upgrade the plan just long enough to dump.
scripts/db/dump-from-neon.sh
pg_dump + emit a manifest of pg_stat_user_tables row counts. Plain SQL
format (auditable, diff-friendly). Halts the script if SOURCE_DATABASE_URL
is missing.
scripts/db/restore-to-target.sh
psql --single-transaction --set ON_ERROR_STOP=on against the new host.
Refuses to overwrite a target that already has users rows (set
RECREATE_DB=1 to force). After restore, compares pg_stat_user_tables
row counts against the source manifest and halts if any table
mismatches — keeps a botched migration from making it to "flip Vercel."
scripts/db/SETUP_HETZNER.md
Runbook from "open Hetzner account" to "Vercel deployed + smoke passes"
for a CX22 (~€4.5/mo). Covers Postgres 17 install, SSL, ufw, fail2ban,
pg_hba, env swap, smoke. ~30 min end-to-end.
scripts/db/SETUP_ORACLE_FREE.md
Same shape for Oracle Always-Free ARM (4 OCPU / 24 GB / free forever).
Calls out the gotchas: dual firewall (Oracle Security List + iptables),
ARM-specific Postgres package source, idle-reclamation risk.
scripts/db/README.md
6-step end-to-end migration cookbook tying the scripts and runbooks
together. Why pg_dump over Drizzle migrations: data move, not schema
sync. Why keep the Neon dump cold for 30 days post-migration.
Today the toolkit can't actually run end-to-end because Neon's quota is
blocking pg_dump. That'll clear on monthly reset (or with a one-month
plan upgrade just long enough to dump). When it does, the full migration
is a coffee break, not a project.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>