- Add Sandbox.fork(...) to the SDK and sandbox fork <source> to the CLI for forking an existing sandbox into a new one
- Fork copies config parameters resources (vcpus), timeout, networkPolicy, tags, ports, persistent, snapshotExpiration, keepLastSnapshots and allows the caller to override any of them
- Raw snapshot IDs are now supported via sandbox create --snapshot <id> and Sandbox.create({ source: { type: "snapshot", snapshotId } })
- Remove sandbox create --sandbox-snapshot <name> and Snapshot.fromSandbox(name), use sandbox fork <name> / Sandbox.fork({ sourceSandbox: name }) instead
From Vercel Sandbox
Minor Changes
-
Add
Sandbox.fork(...)to the SDK andsandbox fork <source>to the CLI for forking an existing sandbox into a new one. The fork copies as many config parameters as the server exposes —resources(vcpus),timeout,networkPolicy,tags,ports,persistent,snapshotExpiration,keepLastSnapshots— and lets the caller override any of them. Environment variables are not copied (encrypted server-side) and must be re-supplied viaenv/--env. (#205)Breaking: removed
sandbox create --sandbox-snapshot <name>andSnapshot.fromSandbox(name). Usesandbox fork <name>/Sandbox.fork({ sourceSandbox: name })instead. Raw snapshot IDs are still supported viasandbox create --snapshot <id>andSandbox.create({ source: { type: "snapshot", snapshotId } }).