Submit

MCPShell

@inercia

Run shell scripts and command line tools as MCP tools.
Overview

Description

The MCPShell is a tool that allows LLMs to safely execute command-line tools through the Model Context Protocol (MCP). It provides a secure bridge between LLMs and operating system commands.

In other words, you can define all the command line tools for your LLM in a YAML file and let it run them for you...

Features

  • Flexible command execution: Run any shell commands as MCP tools, with parameter substitution through templates.
  • Configuration-based tool definitions: Define tools in YAML with parameters, constraints, and output formatting.
  • Security through constraints: Validate tool parameters using CEL expressions before execution, as well as optional sanboxed environments for running commands.
  • Robust error handling: Graceful recovery from panics with detailed logging.
  • Simple integration: Works with any LLM client supporting the MCP protocol (ie, Cursor, VSCode, Witsy...)

Server Config

{
  "mcpServers": {
    "mcpshell": {
      "command": "go",
      "args": [
        "run",
        "github.com/inercia/MCPShell@v0.1.4",
        "mcp",
        "--config",
        "https://raw.githubusercontent.com/inercia/MCPShell/refs/heads/main/examples/kubectl-ro.yaml"
      ]
    }
  }
}
© 2025 MCP.so. All rights reserved.

Build with ShipAny.