ezssh-mcp
Enables executing commands and transferring files over SSH on multiple hosts concurrently, with auto-discovery from SSH config and support for various authentication methods.
README
ezssh-mcp
Easy SSH MCP Server - Execute commands and transfer files via SSH with AI assistance.
Features
- 🖥️ Cross-platform: Linux, macOS, Windows
- 🔑 SSH Agent support: System SSH Agent, 1Password, Windows OpenSSH
- 📋 Auto-discovery: Reads hosts from
~/.ssh/config - ⚡ Concurrent execution: Run commands on multiple hosts simultaneously
- 📁 File transfer: Upload/download via SFTP
- 🔗 MCP Resources: SSH hosts exposed as resources for AI access
- 🤖 Multi-AI compatible: Works with Claude, ChatGPT, Gemini and other MCP-compatible clients
Installation
From npm (Recommended)
npm install -g ezssh-mcp
From Source
git clone https://github.com/laomeifun/ezssh-mcp.git
cd ezssh-mcp
npm install
npm run build
Quick Start
1. Run as MCP Server
ezssh-mcp
# or
npx ezssh-mcp
2. Configure with Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"ssh": {
"command": "npx",
"args": ["-y", "ezssh-mcp"]
}
}
}
Or if installed globally:
{
"mcpServers": {
"ssh": {
"command": "ezssh-mcp"
}
}
}
Tools
| Tool | Description |
|---|---|
ssh_list_hosts |
List available SSH hosts from config |
ssh_execute |
Execute commands on one or more hosts |
ssh_transfer |
Upload/download files via SFTP |
ssh_execute
Execute commands on multiple hosts concurrently:
{
"hosts": ["web1", "web2", "web3"],
"command": "uptime"
}
Direct connection (without SSH config):
{
"hosts": ["192.168.1.100"],
"command": "uptime",
"username": "root",
"password": "your-password",
"port": 22
}
ssh_transfer
Upload files:
{
"direction": "upload",
"hosts": ["web1", "web2"],
"localPath": "./dist/app.zip",
"remotePath": "/opt/app/app.zip"
}
Download files (with {host} placeholder for multiple hosts):
{
"direction": "download",
"hosts": ["web1", "web2"],
"localPath": "./logs/{host}.log",
"remotePath": "/var/log/app.log"
}
Resources
SSH hosts are exposed as MCP resources with URI format ssh://<host-name>.
Environment Variables
| Variable | Description | Default |
|---|---|---|
SSH_CONFIG_PATH |
SSH config file path | ~/.ssh/config |
SSH_KNOWN_HOSTS_PATH |
known_hosts file path | ~/.ssh/known_hosts |
SSH_AUTH_SOCK |
SSH Agent socket path | System default |
SSH_TIMEOUT |
Connection timeout (ms) | 30000 |
SSH_STRICT_HOST_KEY |
Strict host key checking | false |
SSH_MAX_CONCURRENCY |
Max concurrent connections | 10 |
Development
# Install dependencies
npm install
# Development mode (watch)
npm run dev
# Build
npm run build
# Type check
npm run typecheck
# Run tests
npm test
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.