rocks-db
设置指南:Fullscale Rocks MCP 服务器
本指南介绍了如何安装、配置和启动 fullscale-rocks 数据库的 MCP 服务器。
1. 安装
如果尚未安装,请安装依赖项:
cd rocks-mcp
npm installRelated MCP server: DB MCP Server
2. 配置
服务器需要数据库凭据和 OAuth 公钥。
数据库设置
创建或编辑 rocks-mcp/.env:
MYSQL_HOST=127.0.0.1
MYSQL_PORT=3306
MYSQL_DATABASE=employee
MYSQL_USER=employee
MYSQL_PASSWORD=thisisapassword
PG_HOST=127.0.0.1
PG_PORT=5432
PG_DATABASE=employee
PG_USER=employee
PG_PASSWORD=thisisapassword
SSE_PORT=3001身份验证
服务器会自动在以下位置查找 OAuth 公钥:
/home/ryscript/fullscale-rocks/rocks-api/storage/oauth-public.key
请确保该文件存在,因为它用于验证来自 rocks-api 的 JWT 令牌。
3. 运行服务器
开发模式
使用 tsx 运行服务器(文件更改时自动重载):
npm run dev生产模式
构建 TypeScript 代码并启动构建版本:
npm run build
npm start4. 连接到 AI 应用程序
Claude Desktop
将此配置添加到你的 claude_desktop_config.json 中:
{
"mcpServers": {
"rocks-db": {
"command": "node",
"args": ["/home/ryscript/fullscale-rocks/rocks-mcp/build/index.js"]
}
}
}通用 MCP 客户端 (SSE)
服务器还支持用于远程或基于 Web 的客户端的服务器发送事件 (SSE)。
SSE URL:
http://localhost:3001/ssePost Message URL:
http://localhost:3001/message
你可以将其与 MCP Inspector 或其他兼容 SSE 的客户端一起使用。
5. 工具参考
服务器公开了以下工具:
工具 | 用途 | 要求 |
| 运行 |
|
| 运行 |
|
| 列出所有表 |
|
| 显示表的列信息 |
|
注意:auth_token 应为从 rocks-api 登录过程中获得的有效 Bearer 令牌。
This server cannot be deployed
Maintenance
Related MCP Connectors
Create, manage, and query your Google Cloud SQL resources.
Query Postgres, MySQL, SQL Server, Oracle, BigQuery, ClickHouse and Redshift from your AI client.
Explore, query, and inspect SQLite databases with ease. List tables, preview results, and view det…
- WoWSQLOAuthcom.wowsql
Managed Postgres MCP: projects, SQL, docs search, and storage buckets via OAuth.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables secure interaction with MySQL databases through SQL queries, supporting read-only operations without approval and write operations with user confirmation.6 npmISC
- AlicenseAqualityDmaintenanceEnables executing SQL queries, schema introspection, and data management for PostgreSQL and MySQL databases via natural language, supporting local, SSH, and AWS RDS connections.8145 npmMIT
- FlicenseAqualityDmaintenanceEnables read-only exploration and querying of PostgreSQL or MySQL databases via MCP, with schema discovery, safe SQL validation, natural language to SQL conversion, and CSV export.111-
- FlicenseNot gradedqualityDmaintenanceEnables secure SQL query execution on MySQL databases with authentication and permission control, allowing users to explore database tables and run read-only queries.-