Skip to content

[Feature]: First-class multi-instance management for Docker installs #39659

Closed

Description

@diligentapple

Summary

Overview

OpenClaw’s Docker install path works well for running a single instance, but having multiple instances running on a single host is still quite manual.

So I think this is a real product gap for power users and self-hosters.

Why upstream

There are already community wrappers that prove this is useful, but I think the underlying primitives are important enough to be supported officially in a minimal way rather than left to fragmented shell scripts.

If this direction makes sense, I’d be happy to help with a narrowly scoped PR. Thanks!

Problem to solve

Users who want multiple OpenClaw instances on the same VPS typically have to manage their own:

  • container / compose project naming
  • host port allocation
  • per-instance config and workspace directories
  • update / recreate flow
  • deletion and cleanup flow

Proposed solution

Add a minimal, first-class multi-instance lifecycle / commands for Docker installs:

openclaw instance create
openclaw instance list
openclaw instance delete
openclaw instance update

Functions:

  • isolated persistent directory per instance
  • isolated compose project/container names
  • explicit host port assignment per instance
  • safe create / list / delete / update workflow

Alternatives considered

No response

Impact

Affected:
Self-hosted OpenClaw users running Docker deployments, especially power users operating multiple agents or environments on a single VPS/server.

Severity:
Not usually a hard blocker for single-instance users, but for multi-instance users it becomes a meaningful workflow problem. It's more like a recurring operational pain point.

Frequency:
For users managing more than one instance, this pain occurs consistently whenever they create, update, delete instances.

Consequence:
Without first-class multi-instance support, users must manually manage ports, container names, volumes, config directories, workspace isolation... easily causing issues and extra debugging work.

Evidence/examples

No response

Additional information

No response

Activity

  1. added
    enhancement
    on Mar 8, 2026
  2. clawsweeper commented on Apr 26, 2026

    @clawsweeper
    Contributor

    Thanks for the context here. I did a careful shell check against current main, and this is already implemented.

    Close as implemented on current main. The experimental openclaw fleet host-side lifecycle now covers the requested multi-instance Docker workflow with isolated cells, ports, persistent state, upgrades, and safe removal; it is newer than the latest release.

    So I’m closing this as already implemented rather than keeping a duplicate issue open.

    Review details

    Best possible solution:

    Use the documented experimental Fleet lifecycle for multi-instance Docker or Podman hosting, while retaining the Compose setup path for ordinary single-instance installs.

    Do we have a high-confidence way to reproduce the issue?

    Not applicable: this is a feature request rather than a report of a failing established behavior. Current main source and docs provide the requested lifecycle through openclaw fleet.

    Is this the best way to solve the issue?

    Yes. Fleet is a better-maintained solution than adding parallel instance commands because it centralizes per-cell state, container lifecycle, port allocation, health checks, and deletion safety in one host-side subsystem.

    Security review:

    Security review: No patch is under review; current Fleet documentation describes a security-scoped per-cell container profile.

    AGENTS.md: found and applied where relevant.

    What I checked:

    • Current CLI implements the requested lifecycle: Current main registers openclaw fleet create, list, start, stop, restart, upgrade, and rm; these are the supported equivalents of the requested instance create/list/update/delete lifecycle. (src/cli/fleet-cli/register.ts:57, a8dfd37332fd)
    • Current service owns isolation and port allocation: Fleet reserves a cell with a dedicated container name and data directory, allocates a loopback host port, creates the cell network, and starts the container through the selected local runtime. (src/fleet/service.runtime.ts:195, a8dfd37332fd)
    • User documentation confirms the operator-visible behavior: The Fleet reference defines cells as complete OpenClaw instances with their own Gateway, state, credentials, channel accounts, container, and loopback-only host port; it documents create, list, lifecycle, upgrade, and removal commands. Public docs: docs/cli/fleet.md. (docs/cli/fleet.md:9, a8dfd37332fd)
    • Focused regression coverage exists: The current command tests cover create defaults and option normalization, list routing, removal safety flags, and invalid runtime/port input; service tests cover lifecycle filesystem and removal safety boundaries. (src/cli/fleet-cli/register.test.ts:61, a8dfd37332fd)
    • Git provenance: Available local history attributes the current Fleet command, service, registry, and docs lines to commit de143f27605db6c8d0889b1aa09efd29223c8f42; it is an ancestor of current main and is the best available local provenance for the implementation in this partial checkout. (src/cli/fleet-cli/register.ts:57, de143f27605d)
    • Release check: current-main-only: The latest release tag v2026.7.1 resolves to 2d2ddc43d0dcf71f31283d780f9fe9ff4cc04fe4 and does not contain the Fleet registration or Fleet documentation; a direct diff shows those surfaces are added after that release. The implementation is therefore present on current main but not proven shipped yet. Public docs: docs/cli/fleet.md. (docs/cli/fleet.md:9, a8dfd37332fd)

    Likely related people:

    • Ali Adnan: The available local blame history attributes the Fleet command, service, registry, and documentation lines to this commit; the partial checkout does not expose a finer-grained feature history. (role: available current-source provenance; confidence: low; commits: de143f27605d; files: src/cli/fleet-cli/register.ts, src/fleet/service.runtime.ts, src/fleet/registry.ts)

    Codex review notes: model internal, reasoning high; reviewed against a8dfd37332fd; fix evidence: commit de143f27605d, main fix timestamp 2026-07-31T22:54:51Z.

  3. added
    P2
    clawsweeper:no-new-fix-pr
    clawsweeper:fix-shape-clear
    clawsweeper:needs-maintainer-review
    clawsweeper:needs-product-decision
    impact:session-state
    issue-rating: 🌊 off-meta tidepool
    and removed
    clawsweeper:fix-shape-clear
    on May 16, 2026
  4. added
    clawsweeper:fix-shape-clear
    on Jun 13, 2026
  5. 9 remaining items

  6. added
    clawsweeper:fix-shape-clear
    and removed
    clawsweeper:fix-shape-clear
    on Jul 6, 2026
  7. solomon2773 commented on Jul 11, 2026

    @solomon2773

    Disclosure: I maintain Nora, an Apache-2.0 self-hosted control plane for OpenClaw and Hermes. This issue describes the external-control-plane territory Nora covers today: multiple isolated OpenClaw containers on one Docker host (or registered remote Docker hosts), stable per-agent gateway-port allocation, persisted workspace/config state, and create/start/stop/restart/redeploy/delete plus version history from one dashboard, API, CLI, or MCP surface.

    It is intentionally heavier than a native openclaw instance command, so it does not replace the lightweight CLI path proposed here. If core stays focused on primitives and routes full multi-instance lifecycle to external tooling, Nora may be useful prior art for instance identity, port allocation, redeploy behavior, and cleanup semantics.

  8. added
    P3
    and removed
    impact:session-state
    P2
    clawsweeper:no-new-fix-pr
    clawsweeper:needs-maintainer-review
    clawsweeper:needs-product-decision
    on Jul 31, 2026
  9. steipete commented on Aug 2, 2026

    @steipete
    Contributor

    Implemented on current main in #104527 (5a54244), merged July 11 after this March request. The experimental openclaw fleet lifecycle provides fleet create, list, start, stop, restart, upgrade, and rm for isolated Docker/Podman instances with independent containers, configuration, workspaces/state, and automatic or explicit host ports. Current CLI registration, runtime isolation, lifecycle regressions, and public documentation confirm the full requested create/list/update/delete workflow: https://docs.openclaw.ai/cli/fleet. Important: this is currently available on main and is not present in the older v2026.7.1 release.

  10. locked as resolved and limited conversation to collaborators on Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3enhancementimpact:ux-frictionissue-rating: 🌊 off-meta tidepool

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions