VPS MCP Server
Click on "Deploy 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., "@VPS MCP Server run 'df -h' to check disk usage"
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.
VPS MCP Server 🚀
English Description
An advanced Model Context Protocol (MCP) server designed to turn your VPS into a powerful AI-driven remote workstation. It provides a comprehensive set of tools for command execution, file management, system monitoring, and persistent session handling.
🌟 Key Features
Command Execution: Run shell commands and scripts (Python/Node/Bash) in a sandboxed environment.
Advanced File Management: Read, write, patch, search, and visualize directory trees.
Persistent Sessions: Based on
tmux, allowing AI to handle long-running or interactive tasks.System Monitoring: Real-time process listing and system resource tracking.
Network Capabilities: Make HTTP requests or download large files directly to the VPS.
Flexible Transport: Supports both
stdioandSSE(HTTP) modes.
⚡️ Quick Run with npx
You can run the server directly without cloning the repository:
# stdio mode (for local use)
npx github:zhy1369800/vps-mcp-server
# SSE mode (for remote VPS deployment)
MODE=sse PORT=8080 MCP_TOKEN=your-token npx github:zhy1369800/vps-mcp-server🛠 Tools Reference
Tool | Description |
| Execute a one-off shell command. |
| Run Python, Bash, or Node.js code blocks. |
| List directory contents or generate a recursive tree. |
| Read from or write to files. |
| Edit specific parts of a file (Token-efficient). |
| Search for files by name or content (grep). |
| Get OS info, memory, disk, or process list. |
| Fetch web content or download files to disk. |
| Start, exec, read, or stop persistent |
🚀 Manual Installation
Clone & Install:
git clone https://github.com/zhy1369800/vps-mcp-server.git cd vps-mcp-server npm installBuild:
npm run buildConfigure: Copy
.env.exampleto.envand set yourMCP_TOKEN.Run (SSE Mode):
MODE=sse PORT=8080 npm start
Related MCP server: sidekick
中文说明
这是一个先进的 Model Context Protocol (MCP) 服务端,旨在将您的 VPS 变成一个强大的 AI 驱动远程工作站。它为 AI Agent 提供了完整的指令执行、文件管理、系统监控和持久化会话处理工具集。
🌟 核心特性
指令执行:在沙箱环境中运行 Shell 命令和脚本(Python/Node/Bash)。
高级文件管理:支持读取、写入、增量补丁(Patch)、全文搜索及目录树可视化。
持久化会话:基于
tmux实现,允许 AI 处理耗时较长或需要交互的任务。系统监控:实时查看进程列表、CPU、内存及磁盘占用情况。
网络增强:直接从 VPS 发起 HTTP 请求或下载大文件到磁盘。
双模式支持:支持
stdio本地调用和SSE(HTTP) 远程调用模式。
⚡️ 使用 npx 快速运行
无需克隆代码即可直接启动服务:
# stdio 模式 (本地使用)
npx github:zhy1369800/vps-mcp-server
# SSE 模式 (远程 VPS 部署)
MODE=sse PORT=8080 MCP_TOKEN=your-token npx github:zhy1369800/vps-mcp-server🛠 工具列表
工具名称 | 功能描述 |
| 执行一次性 Shell 命令。 |
| 运行 Python、Bash 或 Node.js 代码块。 |
| 列出目录内容或生成递归目录树(支持排除目录)。 |
| 读取或写入文件。 |
| 增量编辑文件特定部分(极度节省 Token)。 |
| 按名称或内容搜索文件(基于 grep)。 |
| 获取系统概览、内存、磁盘或进程列表。 |
| 发起 HTTP 请求或下载文件到 VPS 磁盘。 |
| 启动、执行、读取或停止持久化的 |
🚀 手动安装步骤
克隆与安装:
git clone https://github.com/zhy1369800/vps-mcp-server.git cd vps-mcp-server npm install编译:
npm run build配置环境: 将
.env.example复制为.env并设置您的MCP_TOKEN。启动服务 (SSE 模式):
MODE=sse PORT=8080 npm start
🛡 安全建议
建议在 Docker 容器中运行此服务,并配合 Nginx 反向代理(配置 SSL 证书)以确保通信安全。
📄 开源协议
MIT
Available Tools
17 toolsagy_askB
向 agy 提问,自动维护上下文会话 ID。支持直接在普通沙盒中执行,或指定持久化的 tmux 会话执行并自动读取完毕后一次性返回。
Inputs: prompt (required), mode, agent, clear, +6 more.
file_deleteC
删除文件或目录
Inputs: filepath (required).
file_patchC
增量编辑文件(搜索并替换)
Inputs: search (required), replace (required), filepath (required).
file_readC
读取文件内容
Inputs: filepath (required).
file_searchC
搜索文件名或文件内容
Inputs: query (required), type, dirpath, recursive.
file_writeC
写入文件
Inputs: content (required), filepath (required).
get_system_statusB
获取 VPS 系统状态或进程列表
Inputs: sort, type.
http_requestC
发起 HTTP 请求或下载文件
Inputs: url (required), body, method, headers, +1 more.
kill_processC
终止指定 PID 的进程
Inputs: pid (required), force.
list_filesB
列出目录内容或递归获取目录树
Inputs: depth, dirpath, exclude, recursive.
run_commandB
在 VPS 沙盒中执行 Shell 命令(一次性)
Inputs: command (required), cwd, timeout.
run_scriptC
执行脚本代码 (python/bash/node)
Inputs: code (required), language (required), timeout.
send_smsC
使用 Twilio API 发送短信 (SMS)
Inputs: to (required), body (required), from, authToken, +1 more.
session_execC
向已有会话发送命令
Inputs: command (required), sessionId (required).
session_readC
读取会话的最近输出
Inputs: sessionId (required), maxChars.
session_startC
启动一个持久 tmux 会话
Inputs: sessionId (required), cwd, command.
session_stopC
停止并销毁会话
Inputs: sessionId (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 17 tools
Each tool has a distinct purpose: file operations (write, read, delete, patch, list, search), session management (start, exec, read, stop), command/script execution, system status, process control, HTTP requests, SMS, and an AI query tool. No two tools serve the same function, and descriptions clearly differentiate them.
Most tools follow a consistent verb_noun pattern in snake_case (e.g., file_write, session_start). One tool, 'agy_ask', breaks the pattern as noun_verb, but overall naming is predictable and readable.
With 17 tools, the set is well-scoped for a VPS management server. It covers file operations, command execution, session management, system monitoring, HTTP requests, and additional utilities like SMS and AI querying without being overwhelming or sparse.
The tool set covers core VPS operations: file CRUD, command/script execution, session management, system status, and process control. Minor gaps exist, such as package management or network configuration tools, but the surface is sufficient for typical sandbox interactions.
Maintenance
Related MCP Connectors
Connect ChatGPT and Claude to your Mac, Windows or Linux with secure MCP remote access.
Remote MCP server exposing your Node Command fleet (files, shell, processes, browser) to AI hosts.
Remote MCP server for supportsheep: run AI interviews and manage support content for your blog.
Remote MCP server for supportsheep: run AI interviews and manage support content for your blog.
Related MCP Servers
- AlicenseAqualityCmaintenanceMCP server for SSH and local terminal access. Supports interactive commands, long-running processes, and TUI apps like tmux/zellij64MIT
- AlicenseNot gradedqualityBmaintenanceEnables persistent remote VPS collaboration with MCP tools, live dashboard, and autonomous AI agent for code execution, memory, and task automation.175 npm3GPL 3.0
- AlicenseAqualityDmaintenanceEnables reading, writing, editing, searching, running commands, transferring files, and using git on a remote Linux server over SSH via MCP tools.223AGPL 3.0
- AlicenseNot gradedqualityCmaintenanceEnables AI clients to operate on a remote Linux server over MCP, allowing shell command execution, file editing, package installation, project builds, and service management.MIT