Code Sandbox MCP
コードサンドボックス MCP 🐳
Dockerコンテナ内でコードを実行するための安全なサンドボックス環境。このMCPサーバーは、コンテナ化によってセキュリティを維持しながら、AIアプリケーションに安全で隔離されたコード実行環境を提供します。
🌟 特徴
柔軟なコンテナ管理: コード実行用の分離された Docker コンテナを作成および管理します。
カスタム環境のサポート: 任意の Docker イメージを実行環境として使用できます
ファイル操作: ホストとコンテナ間のファイルとディレクトリの簡単な転送
コマンド実行: コンテナ化された環境内で任意のシェルコマンドを実行します。
リアルタイムログ:コンテナのログとコマンド出力をリアルタイムでストリーミング
自動更新: 組み込みの更新チェックと自動バイナリ更新
マルチプラットフォーム: Linux、macOS、Windowsをサポート
Related MCP server: shemcp
🚀 インストール
前提条件
クイックインストール
Linux、MacOS
curl -fsSL https://raw.githubusercontent.com/Automata-Labs-team/code-sandbox-mcp/main/install.sh | bashウィンドウズ
# Run in PowerShell
irm https://raw.githubusercontent.com/Automata-Labs-team/code-sandbox-mcp/main/install.ps1 | iexインストーラーは次のことを実行します。
Dockerのインストールを確認する
システムに適したバイナリをダウンロードしてください
必要な設定ファイルを作成する
手動インストール
リリースページから、お使いのプラットフォームの最新リリースをダウンロードしてください。
バイナリをPATH内のディレクトリに配置する
実行可能にする (Unix 系システムのみ):
chmod +x code-sandbox-mcp
🛠️ 利用可能なツール
sandbox_initialize
コード実行用の新しいコンピューティング環境を初期化します。指定された Docker イメージに基づいてコンテナを作成します。
パラメータ:
image(文字列、オプション): ベース環境として使用する Docker イメージデフォルト: 'python:3.12-slim-bookworm'
戻り値:
この環境と対話するために他のツールで使用できる
container_id
copy_project
ディレクトリをサンドボックス化されたファイルシステムにコピーします。
パラメータ:
container_id(文字列、必須): 初期化呼び出しから返されたコンテナのIDlocal_src_dir(文字列、必須): ローカルファイルシステム内のディレクトリへのパスdest_dir(文字列、オプション): サンドボックス環境の src ディレクトリを保存するパス
write_file
サンドボックス化されたファイルシステムにファイルを書き込みます。
パラメータ:
container_id(文字列、必須): 初期化呼び出しから返されたコンテナのIDfile_name(文字列、必須): 作成するファイルの名前file_contents(文字列、必須): ファイルに書き込む内容dest_dir(文字列、オプション): ファイルを作成するディレクトリ (デフォルト: ${WORKDIR})
sandbox_exec
サンドボックス環境でコマンドを実行します。
パラメータ:
container_id(文字列、必須): 初期化呼び出しから返されたコンテナのIDcommands(配列、必須): サンドボックス環境で実行するコマンドのリスト例: ["apt-get update", "pip install numpy", "python script.py"]
copy_file
サンドボックス化されたファイルシステムに単一のファイルをコピーします。
パラメータ:
container_id(文字列、必須): 初期化呼び出しから返されたコンテナのIDlocal_src_file(文字列、必須): ローカルファイルシステム内のファイルへのパスdest_path(文字列、オプション): サンドボックス環境でファイルを保存するパス
sandbox_stop
実行中のコンテナ サンドボックスを停止して削除します。
パラメータ:
container_id(文字列、必須): 停止して削除するコンテナのID
**説明:**指定されたコンテナを 10 秒のタイムアウトで正常に停止し、ボリュームとともに削除します。
コンテナログリソース
コンテナ ログへのアクセスを提供する動的リソース。
リソースパス: containers://{id}/logs
MIMEタイプ: text/plain
**説明:**指定されたコンテナからのすべてのコンテナ ログを単一のテキスト リソースとして返します。
🔐 セキュリティ機能
Dockerコンテナを使用した分離された実行環境
Dockerコンテナの制約によるリソース制限
stdout と stderr ストリームを分離する
🔧 構成
クロードデスクトップ
インストーラーは自動的に設定ファイルを作成します。手動で設定する必要がある場合は、以下の手順に従ってください。
リナックス
// ~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"code-sandbox-mcp": {
"command": "/path/to/code-sandbox-mcp",
"args": [],
"env": {}
}
}
}macOS
// ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"code-sandbox-mcp": {
"command": "/path/to/code-sandbox-mcp",
"args": [],
"env": {}
}
}
}ウィンドウズ
// %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"code-sandbox-mcp": {
"command": "C:\\path\\to\\code-sandbox-mcp.exe",
"args": [],
"env": {}
}
}
}その他のAIアプリケーション
MCP サーバーをサポートするその他の AI アプリケーションの場合は、コード実行バックエンドとしてcode-sandbox-mcpバイナリを使用するように構成します。
🛠️ 開発
プロジェクトをローカルでビルドしたり、開発に貢献したりしたい場合は、 DEVELOPMENT.md を参照してください。
📝 ライセンス
このプロジェクトは MIT ライセンスに基づいてライセンスされています - 詳細についてはLICENSEファイルを参照してください。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
AlicenseAqualityFmaintenanceMCP server to give every agent an ephemeral Linux sandboxes for executing shell commands.148MIT- AlicenseAqualityCmaintenanceAn MCP server that provides sandboxed shell command execution with configurable security policies, enabling safe AI-assisted command runs within a project repository.3432MIT
- Flicense-qualityCmaintenanceEnables executing arbitrary code and Postman collections in isolated Docker sandboxes via an MCP server, with a real-time web dashboard for management.
- AlicenseAqualityCmaintenanceMCP server that gives AI assistants a secure gVisor-isolated sandbox to run Python or JavaScript code, returning stdout, stderr, and exit codes without local access.136MIT
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
An MCP server for deep research or task groups
ArcAgent MCP server for bounty discovery, workspace execution, and verified coding submissions.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Automata-Labs-team/code-sandbox-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server