Skip to content

feat(cli): split bundled session state root from injected config root #1338

Description

@Astro-Han

Today packages/cli/src/runtime-bootstrap.ts derives sessions, runs, artifacts, connections, credentials, settings, and device identity from a single workspaceRoot. A portable Session Bundle must never contain credentials or host configuration, so we need a hard boundary before any bundle export exists.

Scope

  1. Inventory every store rooted by the CLI/runtime bootstrap; classify each as session-owned state vs injected host configuration.
  2. Introduce explicit stateRoot / configRoot inputs at the nearest shared bootstrap seam; current CLI/Desktop paths remain the backward-compatible defaults.
  3. Define one auditable export policy: includes only session-owned state; explicitly excludes credentials, connection configuration, device identity, storage-root marker, temporary activation input, and logs.
  4. Export fails closed on symlinks, path escape, unknown protected entries, or unsafely overlapping roots.
  5. Tests: legacy path compatibility, root isolation, cross-session leakage, symlink/path traversal, credential canaries proving exported material contains no secrets.

Out of scope

Control plane, KV/CAS, compression and size policy, maka activate, activation deduplication.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions