Enables routing and execution of hardware-related tasks on nodes equipped with Arduino connectivity and capabilities.
Automatically offloads and executes Docker container commands, builds, and management tasks across distributed cluster nodes.
Distributes Jest test suites across the cluster for parallel execution and improved testing throughput.
Provides distributed command execution and task routing specifically targeting x86_64 Linux nodes within the cluster.
Routes and executes commands across macOS-based nodes, supporting both Intel and ARM64 architectures for distributed tasks.
Automatically routes and executes Mocha-based test suites across optimal cluster nodes.
Offloads Node.js package management and build tasks to the most suitable nodes in the distributed network.
Routes LLM inference and model-serving workloads to dedicated inference nodes running Ollama.
Automatically routes pnpm build and installation commands to optimal nodes based on current cluster load.
Supports distributed execution of Podman container operations and builds across the node network.
Enables parallel and distributed execution of Python test suites via pytest across the agentic cluster.
Routes Swift compilation and build tasks to macOS nodes within the cluster.
Supports routing orchestration and coordination tasks to cluster nodes configured with Temporal.
Supports execution of commands and containerized workloads specifically targeting Ubuntu environments on Linux nodes.
Automatically offloads Yarn-based build processes and package management tasks to available cluster resources.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Cluster Execution MCP Serverrun my test suite in parallel across the cluster nodes"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Cluster Execution MCP Server
Cluster-aware command execution for distributed task routing across the AGI agentic cluster.
Version: 0.2.0
Features
Automatic task routing: Commands routed to optimal nodes based on load, capabilities, and requirements
Multi-node support: macpro51 (Linux x86_64), mac-studio (macOS ARM64), macbook-air (macOS ARM64), inference node
Dynamic IP resolution: mDNS, DNS, and fallback methods with caching
Security hardened: No shell injection, environment-based configuration, command validation
SSH connectivity verification: Retry logic with configurable timeouts
Parallel execution: Distribute commands across cluster for maximum throughput
Installation
Configuration
Claude Code Configuration
Add to ~/.claude.json:
Environment Variables
All configuration is externalized via environment variables:
Variable | Default | Description |
|
| SSH username for remote execution |
|
| SSH connection timeout (seconds) |
|
| Initial SSH connect timeout (seconds) |
|
| Number of SSH retry attempts |
|
| CPU usage % threshold for offloading |
|
| Load average threshold for offloading |
|
| Memory usage % threshold for offloading |
|
| Command execution timeout (seconds) |
|
| Status check timeout (seconds) |
|
| IP resolution cache TTL (seconds) |
|
| Gateway IP for route detection |
|
| DNS server for IP detection |
|
| Base path for databases |
Node Configuration
Node hostnames and IPs can be customized:
Variable | Default | Description |
|
| Mac Pro hostname |
|
| Mac Pro fallback IP |
|
| Mac Studio hostname |
|
| Mac Studio fallback IP |
|
| MacBook Air hostname |
|
| MacBook Air fallback IP |
|
| Inference node hostname |
|
| Inference node fallback IP |
MCP Tools
Tool | Description |
| Execute bash commands with automatic cluster routing |
| Get current cluster state and load distribution |
| Explicitly route command to specific node |
| Run multiple commands in parallel across nodes |
Usage Examples
Automatic Routing
Force Specific Requirements
Explicit Node Routing
Parallel Execution
Cluster Status
Cluster Nodes
Node | OS | Arch | Capabilities | Specialties |
| Linux | x86_64 | docker, podman, raid, nvme, compilation, testing, tpu | compilation, testing, containerization, benchmarking |
| macOS | ARM64 | orchestration, coordination, temporal, mlx-gpu, arduino | orchestration, coordination, monitoring |
| macOS | ARM64 | research, documentation, analysis | research, documentation, mobile |
| macOS | ARM64 | ollama, inference, model-serving, llm-api | ollama-inference, model-serving |
Offload Patterns
Commands matching these patterns are automatically offloaded:
Build:
make,cargo,npm,yarn,pnpmTest:
pytest,jest,mocha,testCompile:
gcc,g++,clangContainer:
docker,podman,kubectlFile ops:
rsync,scp,tar,zip,find,grep -r
Commands that stay local:
Simple:
ls,pwd,cd,echo,cat,head,tail,which,type
Security
Shell Injection Prevention
All commands use subprocess.run() with list arguments where possible:
Command Validation
Commands are validated for dangerous patterns:
rm -rf /rm -rf /*> /dev/sdaFork bombs
And more...
SSH Configuration
StrictHostKeyChecking=accept-new- Accept new hosts but verify returning hostsBatchMode=yes- Non-interactive mode for scriptingConfigurable timeouts and retries
Development
Running Tests
Project Structure
CLI Interface
Monitoring
Check cluster health before operations:
Troubleshooting
MCP server not loading:
Node unreachable:
Commands timing out:
Changelog
v0.2.0
New Features:
Proper package structure with pyproject.toml
Environment-based configuration (no hardcoded credentials)
Shared config module with validation functions
Retry logic for SSH connectivity
IP resolution caching with TTL
Inference node support
Security Improvements:
Eliminated shell injection vulnerabilities
Command validation for dangerous patterns
IP validation rejecting loopback/Docker/link-local
SSH host key handling (accept-new)
Code Quality:
Full type hints throughout codebase
Replaced bare except clauses with specific exceptions
Added comprehensive logging
71 unit tests with mocking
Bug Fixes:
Fixed darwin/macos OS alias handling
Proper timeout handling in SSH operations
Better error messages for failed operations
v0.1.0
Initial release with basic cluster execution
License
MIT
Part of the AGI Agentic System
See also:
Node Chat MCP - Inter-node communication
Enhanced Memory MCP - Persistent memory with RAG
Agent Runtime MCP - Goals and task queue