isolator-mcp

isolator-mcp

1

The Isolator MCP Server is a TypeScript-based server that provides a secure sandbox to execute Python, Go, and JavaScript code. It uses Docker containers for isolation and integrates with the Model Context Protocol (MCP) for secure and configurable code execution.

Isolator MCP Server

isolator-mcp is a Model Context Protocol (MCP) server written in TypeScript, providing a secure code execution sandbox using the embedded isolator Go CLI tool. It allows LLM applications to safely run Python, Go, or JavaScript code snippets.

Features

  • Executes code via the execute_code MCP tool.
  • Supports multiple languages and named snippets.
  • Uses Docker for secure execution.
  • Configurable security and resource limits.
  • Returns structured results with error handling.

Prerequisites

  • Docker for container execution.
  • Go for building the embedded CLI.
  • Node.js and npm for server dependencies.

Installation

  1. Build the isolator Go CLI.
  2. Configure isolator_mcp in isolator_config.json.
  3. Install server dependencies with npm.
  4. Build TypeScript code.
  5. Configure MCP Host settings.

Local Development / Testing

  • Build the Go CLI and TypeScript server.
  • Run the server with Node.js and interact manually for testing.

Architecture & Flow

  1. MCP Host sends requests.
  2. Server processes and validates using index.ts.
  3. Executes in Docker container.
  4. Server handles results and cleans up.
  5. MCP Host responds back to LLM.