Skip to content

Define the Companion and Gateway lifecycle contract #5

Description

@xlinush

Context

The OpenClaw Companion and Gateway are separate Windows components with different distribution models:

  • Companion is delivered through the Microsoft Store.
  • Gateway is delivered as an independently signed, non-Store MSIX.
  • Companion may optionally acquire and install Gateway.
  • Gateway installation may also provide the canonical native-Windows OpenClaw CLI.
  • Existing npm or other native installations may already own the CLI and share state under ~\.openclaw.

Before the Gateway MSIX can move beyond preview use, we need a written and tested lifecycle contract defining how these components interact. Without that contract, installation, updates, rollback, removal, and shared-state handling can conflict or leave users with an unsupported configuration.

Decisions required

Acquisition and installation

  • [MSIX Storage] Decide where to host Gateway MSIX artifacts #6
  • Define how Companion discovers, obtains, and installs the independently signed Gateway MSIX.
  • Specify user-consent behavior and the supported Windows deployment API or App Installer flow.
  • Confirm with Partner Center that a Store app may download and initiate installation of a separate non-Store executable package.
  • Define behavior when Gateway is already installed independently.

Identity, trust, and version discovery

  • Define the stable publisher and package identity.
  • Define trusted signing and certificate rotation or renewal behavior.
  • Define how Companion discovers available Gateway versions and verifies the update source.
  • Define compatibility rules between Companion, Gateway, and the OpenClaw CLI payload.

Updates, repair, and rollback

  • Decide whether Companion owns Gateway updates.
  • Decide whether openclaw update participates or a generic Gateway update provider is needed.
  • Define upgrade, repair, rollback, and recovery behavior.
  • Define which component detects and stops a running Gateway before an update.
  • Define which component restarts Gateway after a successful update or rollback.
  • Ensure package repair or reset cannot unsafely terminate Gateway or delete shared user state.

Uninstall and shared state

  • Define which component owns shared state under ~\.openclaw.
  • Document what remains after Companion is removed.
  • Document what remains after the Gateway MSIX is removed.
  • Define user-consent and safety requirements for deleting Gateway payload or shared state.
  • Define behavior when npm or another native OpenClaw installation remains on the device.

Companion integration

  • Integrate Companion with this MSIX for native Windows Gateway installation where appropriate instead of WSL or npm.
  • Surface installation, update, repair, and failure states clearly in Companion.
  • Define telemetry and diagnostics ownership across the two components.

Acceptance criteria

  • A reviewed lifecycle contract documents ownership for acquisition, installation, updates, repair, rollback, shutdown, restart, uninstall, and shared state.
  • Partner Center or Store-policy feasibility is confirmed for the selected installation flow.
  • The contract covers independently installed Gateway and existing npm/native installations.
  • Automated or documented end-to-end tests cover install, update, rollback, repair, and uninstall while Gateway is running.
  • Tests verify state preservation and cleanup when either Companion or Gateway is removed.
  • Companion integration follows the approved contract and reports actionable errors for failed lifecycle operations.
  • Production signing and acquisition remain disabled until the lifecycle contract is approved and validated.

Tracked separately from the umbrella packaging discussion in #1.

Source review comments

Activity

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

Metadata

Metadata

Assignees

Labels

P2Normal priority bug or improvement with limited blast radius.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.impact:securityThis issue is about security boundaries, credentials, authz, sandboxing, or sensitive data.issue-rating: 🌊 off-meta tidepoolIssue quality rating does not apply to this item.

Type

Fields

Priority

None yet

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions