Installation

Learn how to install and set up Poly MCP on your system.

System Requirements

  • Operating System: Linux, macOS, or Windows (WSL2)
  • Rust: 1.70 or later (for building from source)
  • Memory: Minimum 512MB RAM
  • Disk Space: ~50MB for binary

Installation Methods

Option 1: Install from crates.io (Recommended)

The easiest way to install Poly MCP is via Cargo:

cargo install poly-mcp

This will download, compile, and install the latest version.

Verify installation:

poly-mcp --version

Option 2: Install from GitHub Releases

Download pre-compiled binaries from our releases page:

# Linux (x86_64)
curl -LO https://github.com/polysystems/mcp/releases/latest/download/poly-mcp-linux-x86_64
chmod +x poly-mcp-linux-x86_64
sudo mv poly-mcp-linux-x86_64 /usr/local/bin/poly-mcp

# macOS (Apple Silicon)
curl -LO https://github.com/polysystems/mcp/releases/latest/download/poly-mcp-macos-arm64
chmod +x poly-mcp-macos-arm64
sudo mv poly-mcp-macos-arm64 /usr/local/bin/poly-mcp

# macOS (Intel)
curl -LO https://github.com/polysystems/mcp/releases/latest/download/poly-mcp-macos-x86_64
chmod +x poly-mcp-macos-x86_64
sudo mv poly-mcp-macos-x86_64 /usr/local/bin/poly-mcp

Option 3: Build from Source

For the latest development version or custom builds:

# Clone the repository
git clone https://github.com/polysystems/mcp
cd mcp

# Build with optimizations
cargo build --release

# The binary will be at target/release/poly-mcp
sudo cp target/release/poly-mcp /usr/local/bin/

Build with specific features:

# Build without GPU monitoring
cargo build --release --no-default-features --features "filesystem,diagnostics,git"

# Build with all features
cargo build --release --all-features

Dependencies

Required

Poly MCP has minimal dependencies and most are bundled:

  • libgit2 (bundled) - For Git operations
  • openssl (system) - For network operations

Optional

For full functionality, install these tools:

Diagnostics Module:

# Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# TypeScript
npm install -g typescript

# ESLint
npm install -g eslint

# Python tools
pip install pylint flake8 mypy

Silent Module (GPU monitoring):

# NVIDIA GPU support
sudo apt install nvidia-utils  # Ubuntu/Debian
brew install nvidia-smi        # macOS (if applicable)

Platform-Specific Instructions

Ubuntu/Debian

# Install dependencies
sudo apt update
sudo apt install -y build-essential pkg-config libssl-dev

# Install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# Install Poly MCP
cargo install poly-mcp

Fedora/RHEL

# Install dependencies
sudo dnf install -y gcc openssl-devel pkg-config

# Install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# Install Poly MCP
cargo install poly-mcp

macOS

# Install Homebrew (if not installed)
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

# Install dependencies
brew install openssl pkg-config

# Install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# Install Poly MCP
cargo install poly-mcp

Windows (WSL2)

# Enable WSL2
wsl --install

# Inside WSL2, follow Ubuntu instructions
sudo apt update
sudo apt install -y build-essential pkg-config libssl-dev
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
cargo install poly-mcp

Docker Installation

Run Poly MCP in a container:

# Pull the image
docker pull polysystems/poly-mcp:latest

# Run the container
docker run -it --rm polysystems/poly-mcp:latest

Docker Compose:

version: '3.8'
services:
  poly-mcp:
    image: polysystems/poly-mcp:latest
    volumes:
      - ./workspace:/workspace
    working_dir: /workspace

Verification

After installation, verify everything works:

# Check version
poly-mcp --version

# Run help
poly-mcp --help

# Test basic functionality
echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{}}' | poly-mcp

Expected output (clean JSON-RPC response):

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "protocolVersion": "2024-11-05",
    "serverInfo": {
      "name": "poly-mcp",
      "version": "0.1.0"
    },
    "capabilities": {
      "tools": {}
    }
  }
}

Note: When input is piped (non-interactive), poly-mcp produces no banner or extra output—only clean JSON-RPC responses on stdout. The startup banner only appears when running interactively in a terminal.

Updating

From crates.io

cargo install poly-mcp --force

From source

cd mcp
git pull
cargo build --release
sudo cp target/release/poly-mcp /usr/local/bin/

Uninstallation

# If installed via cargo
cargo uninstall poly-mcp

# If installed manually
sudo rm /usr/local/bin/poly-mcp

Troubleshooting

OpenSSL Errors

Error: error: failed to run custom build command for openssl-sys

Solution:

# Ubuntu/Debian
sudo apt install libssl-dev pkg-config

# Fedora
sudo dnf install openssl-devel

# macOS
brew install openssl
export OPENSSL_DIR=$(brew --prefix openssl)

Cargo Not Found

Error: cargo: command not found

Solution:

# Install Rust and Cargo
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# Add to PATH (or restart terminal)
source $HOME/.cargo/env

Permission Denied

Error: Permission denied when moving binary

Solution:

# Use sudo for system directories
sudo mv poly-mcp /usr/local/bin/

# Or install to user directory
mkdir -p ~/.local/bin
mv poly-mcp ~/.local/bin/
export PATH="$HOME/.local/bin:$PATH"

Next Steps