Skip to content

Commit 09eb0f9

Browse files
author
延枚
committed
docs: 重新组织帮助文档,突出 stdio 模式的简便性
- 新增'快速开始'章节,突出 stdio 模式作为推荐方式 - 将 Docker 相关内容统一到'使用 Docker(可选)'章节 - 明确区分 stdio 模式和 SSE 模式的使用场景 - 添加 Codex 中配置 SSE 模式的说明 - 消除文档中关于模式选择和 Docker 使用的混淆 Change-Id: I10c72da56a2dc3f4a680c43834a8535442a0c81d Co-developed-by: Cursor <noreply@cursor.com>
1 parent acd0b56 commit 09eb0f9

File tree

2 files changed

+281
-146
lines changed

2 files changed

+281
-146
lines changed

README.md

Lines changed: 140 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -181,20 +181,14 @@ alibabacloud-devops-mcp-server integrates various tools, including:
181181

182182
![The personal token authorization page](https://agent-install-beijing.oss-cn-beijing.aliyuncs.com/alibabacloud-devops-mcp-server/img_8.jpg)
183183

184-
### Installing via Smithery
184+
## Quick Start (Recommended: Using Stdio Mode)
185185

186-
To install [AlibabaCloud DevOps](https://www.aliyun.com/product/yunxiao) Server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@aliyun/alibabacloud-devops-mcp-server):
187-
188-
```bash
189-
npx -y @smithery/cli install @aliyun/alibabacloud-devops-mcp-server --client claude
190-
```
186+
**Stdio mode** is the simplest and most common way, suitable for most MCP clients (like Cursor, Claude Desktop, iFlow, etc.). No Docker installation required, just run via npx.
191187

192-
### Install Yunxiao MCP server via MCP marketplace
193-
The MCP market built into Lingma (AlibabaCloud Tongyi Lingma) has already provided the AlibabaCloud Devops MCP service. To install it, simply enter the MCP market in Lingma and search for "Yunxiao DevOps", then click install.
188+
### Option 1: Direct Use via NPX (Simplest)
194189

195-
![Install AlibabaCloud Devops MCP Service from the MCP Market](https://agent-install-beijing.oss-cn-beijing.aliyuncs.com/alibabacloud-devops-mcp-server/img_9.png)
190+
Add the following configuration to your MCP client configuration file:
196191

197-
### Run MCP Server via NPX/Cursor/Claude code etc.
198192
```json
199193
{
200194
"mcpServers": {
@@ -212,53 +206,84 @@ The MCP market built into Lingma (AlibabaCloud Tongyi Lingma) has already provid
212206
}
213207
```
214208

215-
### Run MCP Server via Docker Container
209+
> **Note**:
210+
> - Replace `<YOUR_TOKEN>` with your Yunxiao access token
211+
> - The `-y` flag automatically confirms installation without manual confirmation
212+
> - This method uses **stdio mode**, communicating with the MCP client via standard input/output
216213
217-
#### Option 1: Use Official Image (Recommended)
214+
### Option 2: Install via MCP Marketplace
218215

219-
You can use the official Docker image without building it yourself:
216+
The MCP market built into Lingma (AlibabaCloud Tongyi Lingma) has already provided the AlibabaCloud Devops MCP service. To install it, simply enter the MCP market in Lingma and search for "Yunxiao DevOps", then click install.
220217

221-
```shell
222-
# Pull the official image
223-
docker pull build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0
218+
### Option 3: Install via Smithery
219+
220+
To install [AlibabaCloud DevOps](https://www.aliyun.com/product/yunxiao) Server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@aliyun/alibabacloud-devops-mcp-server):
221+
222+
```bash
223+
npx -y @smithery/cli install @aliyun/alibabacloud-devops-mcp-server --client claude
224224
```
225225

226-
Then use the official image name in your docker run commands instead of `alibabacloud/alibabacloud-devops-mcp-server`.
226+
---
227227

228-
#### Option 2: Build Your Own Image
228+
## Using Docker (Optional)
229229

230-
If you prefer to build the image yourself:
230+
If you need to run the MCP server using Docker, you can choose **stdio mode** or **SSE mode**.
231231

232-
```shell
233-
docker build -t alibabacloud/alibabacloud-devops-mcp-server .
234-
```
232+
### Docker with Stdio Mode
235233

236-
#### 2. Run the Container
234+
This method is similar to using npx directly, but runs through a Docker container.
237235

238-
The MCP server supports two modes: **stdio mode** (default) and **SSE mode** (HTTP).
236+
#### 1. Get Docker Image
239237

240-
##### Stdio Mode (for MCP clients)
238+
**Option 1: Use Official Image (Recommended)**
241239

242-
Run the container directly (using official image):
243240
```shell
244-
docker run -i --rm \
245-
-e YUNXIAO_ACCESS_TOKEN="your_token_here" \
246-
build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0
241+
docker pull build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0
247242
```
248243

249-
Or use an environment file:
244+
**Option 2: Build Your Own Image**
245+
250246
```shell
251-
# Create .env file with: YUNXIAO_ACCESS_TOKEN=your_token_here
252-
docker run -i --rm \
253-
--env-file .env \
254-
build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0
247+
docker build -t alibabacloud/alibabacloud-devops-mcp-server .
248+
```
249+
250+
#### 2. Configure MCP Client
251+
252+
Add the following to your MCP client configuration file:
253+
254+
```json
255+
{
256+
"mcpServers": {
257+
"yunxiao": {
258+
"command": "docker",
259+
"args": [
260+
"run",
261+
"-i",
262+
"--rm",
263+
"-e",
264+
"YUNXIAO_ACCESS_TOKEN",
265+
"build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0"
266+
],
267+
"env": {
268+
"YUNXIAO_ACCESS_TOKEN": "<YOUR_TOKEN>"
269+
}
270+
}
271+
}
272+
}
255273
```
256274

257-
> **Note**: If you built your own image, replace the image name with `alibabacloud/alibabacloud-devops-mcp-server`.
275+
> **Note**:
276+
> - If using a self-built image, replace the image name with `alibabacloud/alibabacloud-devops-mcp-server`
277+
> - This method uses **stdio mode**, with the container communicating via standard input/output
258278
259-
##### SSE Mode (for HTTP access)
279+
### Docker with SSE Mode
280+
281+
SSE mode provides service via HTTP, suitable for scenarios requiring independent service or multi-user support.
282+
283+
#### 1. Start SSE Service
284+
285+
**Using Official Image:**
260286

261-
Run the container in background (using official image):
262287
```shell
263288
docker run -d --name yunxiao-mcp \
264289
-p 3000:3000 \
@@ -269,85 +294,127 @@ docker run -d --name yunxiao-mcp \
269294
node dist/index.js --sse
270295
```
271296

272-
> **Note**: If you built your own image, replace the image name with `alibabacloud/alibabacloud-devops-mcp-server`.
273-
274-
The server will be available at:
275-
- SSE endpoint: `http://localhost:3000/sse`
276-
- Messages endpoint: `http://localhost:3000/messages?sessionId=<session-id>`
297+
**Using Self-Built Image:**
277298

278-
View logs:
279299
```shell
280-
docker logs -f yunxiao-mcp
300+
docker run -d --name yunxiao-mcp \
301+
-p 3000:3000 \
302+
-e YUNXIAO_ACCESS_TOKEN="your_token_here" \
303+
-e PORT=3000 \
304+
-e MCP_TRANSPORT=sse \
305+
alibabacloud/alibabacloud-devops-mcp-server \
306+
node dist/index.js --sse
281307
```
282308

283-
Stop the container:
284-
```shell
285-
docker stop yunxiao-mcp
286-
```
309+
#### 2. Configure MCP Client
287310

288-
#### 3. Configure MCP Client (for stdio mode)
311+
Add the following to your MCP client configuration file:
289312

290-
If you're using a MCP client (like Claude Desktop, Cursor, etc.), configure it to use Docker:
313+
```json
314+
{
315+
"mcpServers": {
316+
"yunxiao": {
317+
"url": "http://localhost:3000/sse"
318+
}
319+
}
320+
}
321+
```
322+
323+
If you need to pass your own token when connecting (instead of using the default token from server startup):
291324

292325
```json
293326
{
294327
"mcpServers": {
295328
"yunxiao": {
296-
"command": "docker",
297-
"args": [
298-
"run",
299-
"-i",
300-
"--rm",
301-
"-e",
302-
"YUNXIAO_ACCESS_TOKEN",
303-
"build-steps-public-registry.cn-beijing.cr.aliyuncs.com/build-steps/alibabacloud-devops-mcp-server:v0.2.0"
304-
],
305-
"env": {
306-
"YUNXIAO_ACCESS_TOKEN": "<YOUR_TOKEN>"
307-
}
329+
"url": "http://localhost:3000/sse?yunxiao_access_token=YOUR_TOKEN_HERE"
308330
}
309331
}
310332
}
311333
```
312334

313-
> **Note**: If you built your own image, replace the image name with `alibabacloud/alibabacloud-devops-mcp-server`.
314-
### Run MCP Server via Docker Compose
315-
1. Environment Setup
335+
#### 3. Manage SSE Service
336+
337+
View logs:
338+
```shell
339+
docker logs -f yunxiao-mcp
340+
```
341+
342+
Stop service:
343+
```shell
344+
docker stop yunxiao-mcp
345+
```
346+
347+
### Run SSE Mode via Docker Compose
348+
349+
1. **Environment Setup**
316350
```shell
317351
cd alibabacloud-devops-mcp-server
318-
cp .env.example
352+
cp .env.example .env
353+
# Edit .env file and set YUNXIAO_ACCESS_TOKEN
319354
```
320355

321-
2. Running the Services:
356+
2. **Start Service**
322357
```shell
323358
docker compose up -d
324359
```
325-
3. Configure MCP Server
360+
361+
3. **Configure MCP Client**
326362
```json
327363
{
328364
"mcpServers": {
329365
"yunxiao": {
330-
"url":"http://localhost:3000/sse"
366+
"url": "http://localhost:3000/sse"
331367
}
332368
}
333369
}
334370
```
335371

336-
### SSE Mode with Custom Tokens
337-
When running in SSE mode, each user can use their own token by passing it as a query parameter or request header:
372+
---
373+
374+
## Advanced SSE Mode Configuration
375+
376+
### Using Custom Tokens
338377

339-
1. Via query parameter:
378+
In SSE mode, each user can pass their own token in the following ways:
379+
380+
1. **Via query parameter** (Recommended):
340381
```
341382
http://localhost:3000/sse?yunxiao_access_token=USER_SPECIFIC_TOKEN
342383
```
343384

344-
2. Via request header:
385+
2. **Via request header**:
345386
```
346387
x-yunxiao-token: USER_SPECIFIC_TOKEN
347388
```
348389

349390
This allows multiple users to share the same SSE service while using their own individual tokens for authentication.
350391

392+
### Configure SSE Mode in Codex
393+
394+
If your Yunxiao MCP server is already running in SSE mode at `http://localhost:3000`, you can configure it in Codex as follows:
395+
396+
**Use default token (configured at server startup):**
397+
```json
398+
{
399+
"mcpServers": {
400+
"yunxiao": {
401+
"url": "http://localhost:3000/sse"
402+
}
403+
}
404+
}
405+
```
406+
407+
**Pass token in URL:**
408+
```json
409+
{
410+
"mcpServers": {
411+
"yunxiao": {
412+
"url": "http://localhost:3000/sse?yunxiao_access_token=YOUR_TOKEN_HERE"
413+
}
414+
}
415+
}
416+
```
417+
351418
### Toolsets
352419
The server now supports toolsets, allowing you to enable only the tools you need. This can reduce the number of tools presented to the AI assistant and improve performance.
353420

0 commit comments

Comments
 (0)