remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
Integrations
Manages environment variables for the MCP server, including AWS credentials and configuration settings.
Used for cloning the MCP server repository during the installation process.
Enables creation of webhooks for GitHub integration with AWS CodePipeline, supporting features like triggering pipelines based on GitHub events such as commits to specific branches.
AWS CodePipeline MCP 服务器
这是一个与 AWS CodePipeline 集成的模型上下文协议 (MCP) 服务器,允许您通过 Windsurf 和 Cascade 管理管道。该服务器提供了与 AWS CodePipeline 服务交互的标准化接口。
作者: Cuong T Nguyen
特征
- 列出所有管道
- 获取管道状态和详细的管道定义
- 列出管道执行
- 批准或拒绝手动批准操作
- 重试失败的阶段
- 触发管道执行
- 查看管道执行日志
- 停止管道执行
- 标记管道资源
- 创建用于自动管道触发的 Webhook
- 获取管道性能指标
先决条件
- Node.js(v14 或更高版本)
- 具有 CodePipeline 访问权限的 AWS 账户
- 具有 CodePipeline、CloudWatch 和 IAM(用于标记)权限的 AWS 凭证
- 带有 Cascade AI 助手的 Windsurf IDE
安装
- 克隆此存储库:
- 安装依赖项:
- 根据
.env.example
模板创建.env
文件:
- 使用您的 AWS 凭证和配置更新
.env
文件:
注意:为了安全起见,切勿将您的
.env
文件提交到版本控制。
用法
构建项目
启动服务器
对于自动重启的开发:
与 Windsurf 集成
该 MCP 服务器旨在与 Windsurf 配合使用,允许 Cascade 通过自然语言请求与 AWS CodePipeline 进行交互。
设置步骤
- 确保服务器正在运行:
- 将服务器配置添加到 Windsurf MCP 配置文件
~/.codeium/windsurf/mcp_config.json
中:
- 如果目录不存在则创建该目录:
- 重新启动 Windsurf 以加载新的 MCP 服务器配置
与 Cascade 一起使用
配置完成后,您可以在 Windsurf 中使用自然语言与 AWS CodePipeline 进行交互。例如:
- “列出我的所有 CodePipeline 管道”
- “显示我的‘生产部署’管道的当前状态”
- “触发‘测试构建’管道”
- “获取我的‘数据处理’管道的指标”
- “为我的‘前端部署’管道创建一个 webhook”
Cascade 会将这些请求转换为适当的 MCP 工具调用。
MCP 工具
核心管道管理
工具名称 | 描述 | 参数 |
---|---|---|
list_pipelines | 列出所有 CodePipeline 管道 | 没有任何 |
get_pipeline_state | 获取特定管道的状态 | pipelineName :管道的名称 |
list_pipeline_executions | 列出特定管道的执行 | pipelineName :管道的名称 |
trigger_pipeline | 触发管道执行 | pipelineName :管道的名称 |
stop_pipeline_execution | 停止管道执行 | pipelineName :管道的名称executionId :执行 ID reason :可选的停止原因 |
管道详细信息和指标
工具名称 | 描述 | 参数 |
---|---|---|
get_pipeline_details | 获取管道的完整定义 | pipelineName :管道的名称 |
get_pipeline_execution_logs | 获取管道执行的日志 | pipelineName :管道的名称executionId :执行 ID |
get_pipeline_metrics | 获取管道的性能指标 | pipelineName :管道名称period :可选指标周期(以秒为单位) startTime :可选指标开始时间endTime :可选指标结束时间 |
管道操作和集成
工具名称 | 描述 | 参数 |
---|---|---|
approve_action | 批准或拒绝手动批准操作 | pipelineName :管道的名称stageName :阶段的名称actionName :操作的名称token :批准令牌approved :表示批准或拒绝的布尔值comments :可选注释 |
retry_stage | 重试失败的阶段 | pipelineName :管道的名称stageName :阶段的名称pipelineExecutionId :执行 ID |
tag_pipeline_resource | 添加或更新管道资源的标签 | pipelineName :管道的名称tags :用于标记的键值对数组 |
create_pipeline_webhook | 为管道创建 webhook | pipelineName :管道的名称webhookName :webhook 的名称targetAction :webhook 的目标操作authentication :身份验证类型authenticationConfiguration :可选的身份验证配置filters :可选的事件过滤器 |
故障排除
常见问题
- 连接被拒绝错误:
- 确保服务器在指定端口上运行
- 检查端口是否被防火墙阻止
- AWS 凭证错误:
- 在
.env
文件中验证您的 AWS 凭证 - 确保您的 IAM 用户具有必要的权限
- 在
- Windsurf 未检测到 MCP 服务器:
- 检查
mcp_config.json
文件格式 - 确保服务器 URL 正确
- 更改后重新启动 Windsurf
- 检查
日志
服务器将信息记录到控制台。检查以下日志以进行故障排除:
示例
为 GitHub 集成创建 Webhook
获取管道指标
执照
国际学习中心
This server cannot be installed
与 AWS CodePipeline 集成的模型上下文协议服务器,允许用户使用自然语言命令通过 Windsurf 和 Cascade 管理管道。
- Features
- Prerequisites
- Installation
- Usage
- Integration with Windsurf
- MCP Tools
- Troubleshooting
- Examples
- License