Skip to content

Remote-SSH as a first-class fleet posture (opt-in) — host-native tooling on the durable hub #1268

Description

@jeonghun-jj-lee

Important

Problem — The product is now host-centric: chat, sessions, /amicode/*, the event stream, and the terminal all resolve to the host (the merged thin-client program). Yet there is no supported path to the host's native dev tooling — under the thin client the native Explorer, language servers, integrated terminal, debugger, source control, and search all operate on the client. ADR 0025 adopts Remote-SSH as the target default posture to deliver the "as if working on the host locally" experience; this issue makes Remote-SSH a first-class, opt-in posture (the default flip is gated separately).
Approach — A one-click opt-in that attaches the local editor to the durable hub host over VS Code Remote-SSH: verify and repair the extension's behavior when it relocates to the host (it declares extensionKind: ["workspace"], the same mechanism devcontainer/WSL already exercise), reach the durable hub (#1258) as a Remote-SSH target, and surface window-mode (Remote-SSH vs thin-client vs standalone) as its own field — never an overload of the link-health posture.
Approaches considered — (a) FSP-only host files (#1267) — rejected as the host-native answer: a virtual scheme carries files but no LSP/terminal/debug/git/search. (b) Remote-SSH as default now — rejected: gated behind the lifeboat auto-switch (ADR 0025 P3) so a degraded link never freezes the editor with no fallback.
Scope — in: the opt-in Remote-SSH entry; the durable hub reachable/verified as a Remote-SSH target; extension-relocation correctness (engine/service/run surfaces resolve to the host when the extension runs host-side); window-mode surfaced as a separate field. · out: the default flip (ADR 0025, gated on P1–P3); the auto-switch (separate issue); credential portability (#782).
Assumptions — extensionKind: ["workspace"] relocation already works for devcontainer/WSL and is the same mechanism; the durable hub service can serve a Remote-SSH-attached editor without a second writer (one canonical writer, ADR 0005).

Acceptance Criteria

  • A user can opt into Remote-SSH from the fleet surface and land in an editor whose native Explorer, integrated terminal, and language features operate on the host.
  • Attaching via Remote-SSH spawns no second engine or store on the host (never-fork; one canonical writer preserved).
  • Window-mode (Remote-SSH / thin-client / standalone) is recorded in its own field, distinct from the link-health posture, and surfaced to the user and agent context.
  • Moving a machine between thin-client and Remote-SSH postures keeps the canonical store single-writer at every step.
  • With Remote-SSH unavailable or unconfigured, the client falls back to the existing thin-client posture with no regression.

Testing Decisions

Extend the fleet posture and durable-hub-service suites; add a relocation-correctness case (extension surfaces resolve to the host when the extension runs host-side); reuse the hub-service test harness rather than a new fixture.

Key Decisions

Constraints & Invariants

  • Never-fork and one canonical writer (ADR 0005); one topology reader (ADR 0023).
  • Loopback-only bind preserved — the host still binds 127.0.0.1; Remote-SSH's channel is the transport, not a new bind.
  • No silent fallback — an unavailable Remote-SSH target is an honest posture, not a silent reroute.

Prior Art

  • The durable hub service and its unit renderers.
  • The fleet posture state + feed and the client attach loop.
  • The pluggable transport providers (tailscale for roaming within Remote-SSH).
  • The devcontainer/WSL relocation behavior (the same extensionKind mechanism).

Source

Notes

This is the enabling posture work. The poor-wifi auto-switch that makes Remote-SSH safe as the default is a separate issue, itself gated on a UI-kind extension split.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions