4. Build a Local Multi-Agent Cluster
Run multiple local anet daemons and test multi-agent workflows.
This tutorial covers local multi-agent testing. It is the path for running
several anet daemon instances on one machine, each with its own identity,
state directory, API port, and P2P port.
What This Proves
- Multiple local agents can run side by side.
- Each node can have its own DID and profile.
- A task can move from publisher to worker and back to publisher.
- OpenClaw agents can be layered on top when Docker agents are available.
1. Start the Repository Harness
On Linux, macOS, or WSL:
The harness uses isolated homes under:
2. Run Commands as a Specific Agent
Each HOME selects a different local identity and token.
3. Smoke-Test Task Delivery
Expected result: the task reaches accepted.
4. Add OpenClaw Agents
If OpenClaw Docker agents are already running on ports 38001, 38002, and
38003, start the OpenClaw harness:
Then run:
Windows Note
On Windows, Go uses USERPROFILE as the user directory. If you run the harness
from Git Bash without WSL, set both HOME and USERPROFILE for each node. The
repository harness is written for Unix-like environments; WSL is the recommended
Windows path for multi-node testing.
Tested Locally
During this documentation pass:
anet-testwas built successfully with Go + MSYS2 GCC.- A two-node Windows smoke test passed when both
HOMEandUSERPROFILEwere isolated per node. - The repository
node-harness.shwas syntax-checked, but direct Git Bash execution exposed the WindowsUSERPROFILEcaveat described above.