Hydra CI的MCP服务器

mcp-hydra是一个MCP服务器,用于与Hydra CI实例交互,提供项目、任务集、构建和评估的查询与触发功能,适用于开发者在模型上下文协议环境中管理和监控持续集成任务。

  • by basile-henry
  • Python
  • 本地部署
  • 1 星标
  • 更新于
在 GitHub 查看 basile-henry/mcp-hydra

使用说明

mcp-hydra

An MCP server for interacting with Hydra CI instances.

Tools

Tool Description
list_projects List all projects on the Hydra instance
get_project Get project details and its jobsets
get_jobset Get jobset details
get_build Get build details by ID
get_latest_build Get the latest (optionally finished) build for a job
list_builds_in_eval List all builds in an evaluation
get_evaluation Get evaluation details
search Search builds and projects
trigger_jobset Trigger a jobset evaluation (requires auth)
set_hydra_url Switch the target Hydra instance URL

Setup

Claude Code

Add to your project's .claude/mcp.json (or ~/.claude/mcp.json for global):

{
  "mcpServers": {
    "hydra": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/mcp-hydra", "mcp-hydra"],
      "env": { "HYDRA_URL": "https://hydra.nixos.org" }
    }
  }
}

Environment variables

Variable Default Description
HYDRA_URL https://hydra.nixos.org Base URL of the Hydra instance
HYDRA_USER Username for write operations (trigger_jobset)
HYDRA_PASSWORD Password for write operations

You can also switch instances at runtime using the set_hydra_url tool.

Development

uv sync --group dev
uv run pytest

References

License

CC0 1.0 - public domain.