Commit Graph
435 Commits
Author SHA1 Message Date
Neil dd0cd5b001 feat(cloud): acceptance report p99 column; wake delivery on the #151/#162 golden (n=22) 2026-11-09 21:27:41 -08:00
Neil 6732b345b2 feat(cloud): acceptance env.setup-script verifies orca.yaml setup in the VM exactly once (core #168) 2026-11-09 21:20:26 -08:00
Neil 5a7484cf20 Merge pull request #169 from nwparker/cloud/w9-eval
feat(cloud): acceptance — billing gate via billing-test accounts, CLI --on cloud, asleep move-delete, staging teams
2026-11-09 21:17:28 -08:00
Neil 78c874ee1f feat(cloud): run orca.yaml setup once for API/CLI/phone/routine workspaces (#168)
Desktop-created cloud workspaces already run setup through orcad's worktree
create after the setup prompt. Workspaces made through createWorkspace use the
VM's primary checkout, which no worktree create touches, so their setup never
ran. Start it detached on create (once per workspace, orcad's env, skipped on
environment builds) and have routine runners wait for it.
2026-11-09 21:16:28 -08:00
Neil 22f8d5abb4 docs(cloud): acceptance findings — CLI create and asleep move-delete closed 2026-11-09 21:15:16 -08:00
Neil d9cd1bac93 feat(cloud): acceptance api.cli runs orca worktree create --on cloud headlessly (W5 #167) 2026-11-09 21:14:53 -08:00
Neil 3b8867d3de feat(cloud): acceptance control-plane billing gate end to end via dev:billing-test-* (#166) 2026-11-09 21:14:53 -08:00
Neil e506a7bca7 Merge pull request #167 from nwparker/cloud/w5-cli-worktree-on
feat(cli): orca worktree create --on cloud (private build) with --env, JSON output and clear plan/at-cap/sign-in errors
2026-11-09 21:13:22 -08:00
Neil 70e9b2a6c4 feat(cli): orca worktree create --on cloud[:<project>] [--env] creates an Orca Cloud workspace (private build); clear plan/at-cap/payment/sign-in errors; API accepts a team environment 2026-11-09 21:08:55 -08:00
Neil f2386f9a37 feat(sandbox-control): dev-only SANDBOX_DEV_BILLING_ENFORCE_PREFIX sends one dev account prefix through the real billing gate (#166)
dev:* accounts skip billing on dev, so W9 could not test the gate (no plan refused, active allowed,
grace expiry suspends, at-cap refused) with dev tokens. Dev accounts under the configured prefix now go
to the billing Worker. Honored only when SANDBOX_ENV is exactly 'dev' and only for a specific
sub-prefix (dev:<word>- or dev:<word>:), never all dev accounts; tests cover prod/staging/test being
ignored and over-broad prefixes being rejected. Dev sets dev:billing-test-.
2026-11-09 21:07:28 -08:00
Neil f04525d7db feat(cloud): acceptance closes idle sleep, agent sign-in persistence, wake-on-message, scheduled routines, file search, usage metering, overage cap and full dunning; web client post-MVP 2026-11-09 21:03:10 -08:00
Neil c77ab2b16c feat(cloud): desktop keystroke n=W9D_KEY_SAMPLES with p99/outlier timeline; life.auto-resume desktop check
- W9D_KEY_SAMPLES (default 10): stats gain p99; each sample records time since the workspace's
  first terminal output and wall clock, plus a histogram and the outliers
- life.auto-resume (W9D_AUTO_RESUME=1, W9D_ONLY=auto-resume): personal AI Gateway secrets for the
  dev user (kimi-k2, never logged, deleted after), Claude runs a 40 s loop, status panel Restart,
  Orca must send continue once and the turn must finish; mapped to catalog life.auto-resume
2026-11-09 21:03:10 -08:00
Neil 1772627e6e fix(cloud): CLI/API workspace sleep (POST /v1/workspaces/:id/sleep) records the deliberate sleep too 2026-11-09 20:47:22 -08:00
Neil a878062983 Merge pull request #163 from nwparker/cloud/w2-predict-gaps
fix(cloud): predictive wake gaps: drag, cross-client sleep cooldown, seat cap
2026-11-09 20:43:41 -08:00
Neil 66170d3213 fix(cloud): a failed user-sleep hint write never fails the sleep (worker deployed before migration 0038) 2026-11-09 20:41:55 -08:00
Neil 0a7785d4b5 fix(cloud): predictive wake gaps: a drag never wakes (press waits for release, drag cancels pending), the sleep cooldown reads the server's last chosen sleep from any client, and a wake is skipped with the owner's seat or team at or one below its running cap 2026-11-09 20:41:25 -08:00
Neil b98feda7f8 feat(cloud): targeted desktop acceptance for #157 (picker sign-in twice, Move then Delete)
- W9D_MODE=targeted: picker sign-in on a fresh profile and again after a sign-out, create +
  keystroke, Move to this computer with Archive afterwards then Delete within seconds (destroyed,
  no suspend/archive error toasts), normal delete
- asleep Delete through the dialog without a Force delete offer is intended: graded pass
- cleanup removes local copies a run made; catalog row + import mapping for move-then-delete
2026-11-09 20:34:07 -08:00
Neil aedfb7f7de feat(cloud): desktop acceptance covers #149 (picker sign-in, asleep Force delete, cross-team delete, sign-in card)
- auth.picker-sign-in: picking the signed-out Orca Cloud row must leave Orca Cloud selected
- life.delete-asleep(-after-move): no wake, Force delete offer, destroyed; life.destroy now a
  normal delete of an awake workspace; D-2 passes on a cross-team destroy or a kept
  "couldn't confirm" row
- vercel-check.ts: confirms each run sandbox is 404 on Vercel and records it in results.json
- catalog rows and import mapping for the new steps
2026-11-09 19:59:49 -08:00
Neil 6bc1fffc67 W8: teammates wake a team workspace from the phone (team-route wake; owner route not widened) (#155)
* feat(w8): teammates wake a team workspace from the phone (team route long-poll wake, same access/billing/cap; owner route stays the fallback)

* test(w8): team wake refuses an admin on a private row, never returns the endpoint; phone never falls back on 401/403
2026-11-09 19:59:10 -08:00
Neil 78fce9977d fix(sandbox-control): the orphan sweep no longer stops warm-pool VMs (their record is the pool row) 2026-11-09 19:49:24 -08:00
Neil d5e57508cf Merge pull request #152 from nwparker/cloud/activity-keepalive
feat(cloud): VM activity, not the desktop, keeps a sandbox's lease alive
2026-11-09 19:44:57 -08:00
Neil 4dee4cc7c6 feat(cloud): VM activity keeps a sandbox alive without a desktop - orcad publishes its work verdict, the cron renews busy leases and sleeps idle ones 2026-11-09 19:41:36 -08:00
Neil 893be16f77 perf(terminal): prove an idle Linux daemon shell from /proc so Enter skips the paste settle (#151)
terminal.send text+Enter to a daemon-backed shell always waited the 500 ms agent paste
settle: the daemon's shell-foreground answer is lifecycle ownership, which is only proven
after a recovery or full-screen exit, never for a fresh or plain-command shell. On Linux
the idle-prompt claim now also accepts the shell's own /proc stat (process group is the
terminal foreground group, i.e. ps '+'), scoped to the target PTY; other hosts unchanged.

The acceptance wake split uses one persistent paired connection per wake (the desktop's
transport) by default; transport=cli keeps the per-call socket the CLI dials.
2026-11-09 19:38:55 -08:00
Neil 05d43602c8 Merge pull request #149 from nwparker/cloud/delete-unconfirmed-fix
fix(cloud): P0 delete leak - never drop a row for an unconfirmed sandbox; creator can delete across teams; asleep delete without wake
2026-11-09 19:33:17 -08:00
Neil 5bdec31000 fix(cloud): address review - asleep delete needs Force delete and runs ownership checks, destroyed sandboxes forget their row, removed members get no cross-team delete, destroy errors always surface 2026-11-09 19:27:29 -08:00
Neil cb7d58bbc0 fix(cloud): deletes never drop a row for a sandbox Orca Cloud can't confirm; asleep cloud delete skips the wake; creator can delete across teams; picker sign-in selects Orca Cloud; signed-out create shows the sign-in card 2026-11-09 19:20:44 -08:00
Neil 1417e042fc feat(cloud): desktop acceptance covers the #127 fixes and runs on a remote Mac
- auth.signed-out-create (D-1/D-4), proj.cloud-name (D-3), life.delete-unconfirmed (D-2,
  team switch -> not_found), life.delete-after-oob-destroy; life.destroy now requires destroyed
  and records the asleep-delete refusal
- starts signed out (dev auth) with no sign-in-then-relaunch workaround; mock keychain so a
  fresh dev app identity does not block on a macOS Keychain prompt
- cloud vs local rows disambiguated by badge (Move to this computer reuses the name)
- upload/download helpers for staging and collecting a run on a paired Orca environment
2026-11-09 19:08:55 -08:00
Neil f2df1de717 feat(cloud): acceptance wake-delivery split benchmark, persistent-connection downloads, golden status helper 2026-11-09 19:08:55 -08:00
Neil d7552c51a0 feat(cloud): acceptance remote-desktop check (ticketed websockify upgrade on the VM loopback) 2026-11-09 19:08:55 -08:00
Neil 75f7919107 docs(cloud): acceptance findings — desktop fixes #127 awaiting UI re-run 2026-11-09 19:08:55 -08:00
Neil 2a075764a7 fix(sandbox-control): golden builds retry apt downloads and wait for the dpkg lock (provision_exit_100) (#147) 2026-11-09 19:06:04 -08:00
Neil 126597343f chore(sandbox-control): operator rotation prints the build's log tail on failure (#145) 2026-11-09 18:55:32 -08:00
Neil 4c1b26e67e Merge remote-tracking branch 'private/cloud/integration' into w6-agent-firstrun
# Conflicts:
#	cloud/apps/sandbox-control/image/vm-scripts.generated.ts
2026-11-09 18:45:39 -08:00
Neil 0a625740cc perf(orcad): skip the disposable startup preflight on Orca Cloud boots (#141)
On every Orca Cloud start and wake, orcad ran its disposable startup preflight child. That child is a
second full load of the 15 MB bundle plus the SQLite and node-pty probes, and it ran before main().
The cloud slot could never be qualified: qualification needed the managed-activation env, and the
marker lives in the slot directory, which is root-owned in the image. In-VM profiles showed the main
thread idle for about 580 ms waiting on that child.

- ORCA_ORCAD_STARTUP_QUALIFICATION_DIR names a writable directory for the startup-qualified marker
  and opts the slot into qualification. The key is unchanged: artifact version, file stat identity,
  runtime, ABI, kernel and launch env. It survives a stop and resume: inode, mtime and ctime are
  identical after resume, and the first launch after resume skipped the preflight.
- The image creates /opt/orca/startup-qualification. The provisioning smoke run records the marker,
  and orca-sandbox-start passes the env.
- Agent-state-rules live updates and speech-model warm-up now start after the ready line instead of
  before it.
- Once the ready line is published, a terminal list warms the terminal path (worktree catalog,
  daemon inventory) before the reconnecting desktop asks for it.

Real 4-vCPU VMs, readyMs median of 5: idle 1475 -> 903 ms; with 3 busy cores 1921 -> 1200 ms.
2026-11-09 18:44:16 -08:00
Neil d98b730df9 fix(cloud): agents start working from the phone/API — Claude Code first-run screens and Codex trust/sandbox pre-answered in the sandbox, no self-update mid-session; 'Open terminal to sign in' opens the terminal (paneView rides with paneKey) 2026-11-09 18:42:25 -08:00
Neil a2dee979c9 feat(sandbox-control): rebuild org environments on the new golden after every golden swap (#140)
Environment snapshots are built on a golden, so workspaces from them kept that golden's orcad and VM
scripts after rotation (e.g. no files.archiveStart). Each 5-minute tick, after the golden tick, every
environment whose active build's base_snapshot_id is not the current golden gets a background rebuild
of the active build's config (only the base image changes), attributed to system:golden-refresh and
billed like any build. The active build serves until the new one succeeds, then the newest-success
activation swaps it atomically; the old snapshot stays for rollback; a failed rebuild keeps the active
build, shows the usual failed build, and is not retried for that golden. At most 2 starts per tick
and 3 builds in flight overall. startBuild accepts an explicit config for this.
2026-11-09 18:33:09 -08:00
Neil 8ef12e5729 fix(cloud): desktop P2 review — unarchiving state, dismissible progress, late/thrown wake failures, one failure message 2026-11-09 18:12:17 -08:00
Neil 724e8bce0b feat(cloud): remote desktop P2 — Unarchive action, wake then open, light reconnect card, palette entry 2026-11-09 18:12:13 -08:00
Neil 63377c810d fix(sandbox-control): source-built goldens provision with the built commit's image files, not the Worker's copies (#137)
The Worker-started source build used the VM scripts, provision script and manifest pins embedded in
the Worker that started it, so a golden built from a newer commit could miss that commit's new VM
scripts (seen live: snap_HTsU from 19f900e has #122's orcad but not orca-desktop-proxy or
orca-desktop-page.js). source-build.sh now sources image/commit-provision-env.mjs from the fetched
checkout (no dependencies; mirrors provisionEnv, enforced by a test), so the image ships exactly that
commit. Tests also require every image/vm file to be a declared VM script and installed by provision.
2026-11-09 18:10:35 -08:00
Neil e998a5ce96 W8 follow-ups: removal and role loss reach phones; role-aware plan-denial copy (#135)
* fix(w8): removing a member revokes their phones; role changes move phones too; a phone's stored role never re-syncs keys

* fix(w8): one removal path revokes keys, phones, grants and routines; stale desktop tokens can't re-sync roles or vouch phones; a grant revoked mid-issue stays revoked

* fix(w8): a removed member's unexpired desktop tokens stop working; changes count from auth's time; desktop re-mints and retries enroll on stale_token

* feat(w8): role-aware plan-denial copy on the phone (owners and admins get the fix, members who to ask)

* fix(w8): W10 copy (per-seat team limit, choose a plan) and FE review (3 s abortable role read, Android live region, more copy cases); no casts
2026-11-09 18:02:56 -08:00
Neil c68f06864a fix(cloud): name the VM project after its repo (orca repo add --display-name); golden builder uses wait=true exit probe; image-only merges rebuild (#133)
* feat(cli,sandbox-control): orca repo add --display-name; cloud sandboxes name the project after its repository

The VM checkout lives at /vercel/sandbox/project, so boot-time registration (#104) named the repo
'project'. repo.add already accepts displayName; the CLI now exposes it as --display-name and
orca-sandbox-start passes the repository basename from ORCA_REPO_URL.

* fix(sandbox-control): golden builder polls detached builds with a bounded wait=true read; image-only merges trigger a rebuild

The provider reports a detached command's exit code only to a wait=true read (W1's finding, #123):
stepBuild's plain GET is what kept finished golden builds 'running' until the deadline. stepBuild and
the operator rotation now use the same bounded wait probe (4 s); the exit-file marker stays as a
fallback. golden-source's VM path list now includes cloud/apps/sandbox-control/image/ (VM scripts,
provision, manifest), so a script-only merge (e.g. orca-desktop-proxy) rebuilds the golden too.
2026-11-09 17:56:20 -08:00
Neil b7eae3fec8 Merge pull request #131 from nwparker/cloud/w9-eval
fix(cloud): acceptance cleans up staging teams via cleanup-teams.mjs
2026-11-09 17:54:23 -08:00
Neil fb332cc4ca Merge pull request #87 from nwparker/cloud/w2-final
feat(cloud): W2 final pass: glossary, control-plane idle minutes, rollover restarting state, Move to this computer flow
2026-11-09 17:51:09 -08:00
Neil fe4ae20d78 fix(cloud): acceptance deletes staging teams via cleanup-teams.mjs (#130), skips team checks when cleanup is unavailable 2026-11-09 17:50:02 -08:00
Neil 56315c1f2b Merge pull request #129 from nwparker/cloud/w9-eval
feat(cloud): acceptance — headless downloads, staging team checks, poll-mode env builds
2026-11-09 17:46:40 -08:00
Neil 8b05b95c98 docs(cloud): acceptance findings — downloads pass on the #115 image 2026-11-09 17:46:24 -08:00
Neil 84b02d6761 Merge remote-tracking branch 'private/cloud/integration' into cloud/w2-final
# Conflicts:
#	src/renderer/src/components/worktree-creation/vm-build-failure.test.ts
2026-11-09 17:43:38 -08:00
Neil eedb151a46 feat(cloud): acceptance headless download check, staging team create/invite, findings 2026-11-09 17:41:37 -08:00
Neil 60377d3364 feat(cloud): remote desktop Beta — single-use tickets, fit, clipboard, keyboard release (W10 RD-1..6) (#122)
* feat(cloud): remote desktop single-use tickets, fit, clipboard and keyboard release

- VM: Xvnc on a 0600 socket with no VNC auth plus an X cookie; orca-desktop-proxy (websockify
  subclass) admits one WebSocket per unused 60 s ticket from the same localhost origin, refuses
  rebinding Hosts, scrubs tickets from logs, serves the page with connect-src 'self'.
- Worker: POST /desktop mints a fresh ticket per call (schemaVersion 2).
- Desktop: no secret in the tab URL; main hands the page tickets on load and reconnect (backoff,
  floor, pause with Reconnect), only for the exact URL of a live forward it opened; keyboard stays
  in the desktop until Ctrl+Cmd / Ctrl+Alt; a paste key pushes this computer's clipboard; sandbox
  copies reach this computer after a copy gesture.
- UI: keyboard hint, asleep/starting neutral tone and mapping, persistent error toasts, Beta badge.

* fix(cloud): remote desktop review fixes

- Security review: noVNC host/port/encrypt pinned to the page's origin, CSP connect-src 'self',
  exact-URL + live-forward trust, mint floor and per-minute cap, copy gate on copy gestures only,
  X display cookie.
- Design review: archived is its own neutral state, starting covers waking, page messages say
  "Wake it in Orca", pause overlay is a status for calm states and focuses Reconnect, hint wraps
  and hides from assistive tech when faded.
- FE review: paste follows the keyboard layout, AltGr never releases, page calls settle on
  navigation, state notices only on change, hint once per load/release, paste always pushes,
  no committed bytecode, session tests.

* fix(cloud): remote desktop archived page message, hint layout, fixtures

* fix(cloud): remote desktop copy gate counts double-clicks (pointer events have no click count)

* chore(cloud): remote desktop lint (exhaustive pause reasons, no test casts or wall clock)
2026-11-09 17:36:19 -08:00
Neil 87da8eb16a Merge remote-tracking branch 'private/cloud/integration' into cloud/w2-final 2026-11-09 17:36:10 -08:00