docker build \
--build-arg ALIYUN_REGION_ID=cn-beijing \
--build-arg ALIYUN_ACCESS_KEY_ID=** \
--build-arg ALIYUN_ACCESS_KEY_SECRET=** \
--build-arg NACOS_SERVER_ADDR=localhost:8848 \
--build-arg NACOS_NAMESPACE=** \
--build-arg NACOS_DATA_ID=mcp_rust.yml \
--build-arg NACOS_GROUP=DEFAULT_GROUP \
--build-arg OFFLINE_MODE=false \
--build-arg CONFIG_FILE=config.yml \
-t mcp-server:latest .- Start MCP server
cargo run- Start MCP client
npx @modelcontextprotocol/inspector sse http://127.0.0.1:3001/sse- Run in Docker in Docker
docker run -d -it -p 3001:3001 --name=test-mcp mcp_service:latest
- Cursor MCP Configuration
{
"mcpServers": {
"mcp-server": {
"url": "http://localhost:3001/sse"
}
}
}
This directory contains the core functional modules related to MCP (Management Control Platform), as follows:
- Function: Responsible for managing MCP-related configuration information.
- Description: Defines and loads the configuration information required by MCP, allowing flexible adjustment of system parameters.
- Function: Utility functions related to time.
- Description: Provides practical methods for time formatting, timestamp conversion, and other time-related processing.
- Function: Aliyun Log CLI tool integration.
- Description: Encapsulates command-line operations for interacting with Aliyun Log Service, facilitating log query and management.
- Function: Aliyun CLI tool integration.
- Description: Encapsulates command-line operations for interacting with various Aliyun services, supporting multiple Aliyun API calls.
- Function: Module aggregation entry point.
- Description: Uniformly exposes the functional modules in this directory for external calls.