linux-harness-mcp
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., "@linux-harness-mcprun 'uname -a' to check system info"
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.
linux-harness-mcp
A Model Context Protocol server that exposes this host as a Linux harness over public-trusted HTTPS. Designed for AI agents that have no Linux runtime of their own — they connect and get shell, Python, and filesystem tools that execute here.
Features
13 MCP tools: shell exec, Python exec, file read/write, directory ops, glob search, health check, opencode run/ultrawork
Basic Auth or Bearer Token authentication
Public HTTPS via ngrok (no certificate management needed)
One-command install with interactive wizard (
lhm install)Systemd service with auto-restart
CLI manager (
lhm) for status, logs, config, diagnostics
Related MCP server: mcp-server
Quick Start
Install via npm
npm install -g linux-harness-mcpInteractive Setup
sudo lhm installThis walks you through bind address, port, authentication, and optional ngrok exposure.
Check Status
lhm statusGet Public Endpoint
lhm url
# https://your-domain.ngrok-free.dev/mcpCLI Reference (lhm)
Command | Description |
| Interactive setup wizard |
| Stop + remove service + ngrok cleanup |
| Show service status + public URL |
| Restart the service |
| View harness logs ( |
| View ngrok tunnel logs |
| Print public MCP endpoint |
| Show configuration (secrets masked) |
| Open config in |
| Run health checks (incl. ngrok) |
| Print version |
MCP Tools
Tool | Description |
| Run shell commands via |
| Execute Python scripts with system |
| Read files (auto text/binary, base64) |
| Write text or base64 binary files |
| List directory entries with metadata |
| Create directories (recursive) |
| Delete files or directories |
| Move/rename paths |
| Get file metadata (type, size, mode, mtime) |
| Glob pattern file search |
| Service health + host summary |
| Execute complex tasks via opencode CLI |
| Execute tasks with ultrawork mode |
Client Configuration
Basic Auth (recommended)
{
"mcpServers": {
"linux-harness": {
"url": "https://your-domain.ngrok-free.dev/mcp",
"headers": {
"Authorization": "Basic <base64(user:pass)>",
"ngrok-skip-browser-warning": "any"
}
}
}
}Bearer Token
{
"mcpServers": {
"linux-harness": {
"url": "http://127.0.0.1:8765/mcp",
"headers": {
"Authorization": "Bearer <token>"
}
}
}
}Architecture
Agent (MCP client)
| HTTPS (TLS 1.2/1.3, Let's Encrypt via ngrok)
v
ngrok :443 --> 127.0.0.1:8765 (uvicorn + FastMCP Streamable HTTP)
|
v
shell / python3 / filesystem (as root)Public ingress: ngrok tunnel to
127.0.0.1:8765MCP transport: Streamable HTTP, stateful sessions
Auth: ASGI middleware (Basic Auth or Bearer Token)
/health: unauthenticated health endpoint
Environment Variables
Variable | Default | Description |
|
| Bind address |
|
| Bind port |
| — | Basic Auth username |
| — | Basic Auth password |
| — | Bearer token (alternative to Basic Auth) |
| — | Comma-separated allowed origins |
Development
# Install in editable mode
pip install -e .
# Run tests
pytest tests/ -q
# Build wheel
python -m build --wheelLicense
MIT
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.
Latest Blog Posts
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/EasonTechno/linux-harness-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server