gitlab-ci-mcp-server
v1.0.0
Published
MCP server for GitLab CI/CD pipeline management — list, trigger, and monitor pipelines and jobs
Maintainers
Readme
gitlab-ci-mcp-server
MCP server for managing GitLab CI/CD pipelines and jobs. Works with any MCP-compatible client (Kiro, Claude Desktop, Cursor, etc.).
Tools
| Tool | Description |
|------|-------------|
| gitlab_list_pipelines | List pipelines with branch/status filtering |
| gitlab_get_pipeline | Get pipeline details (duration, status, etc.) |
| gitlab_create_pipeline | Trigger a new pipeline on a branch |
| gitlab_list_pipeline_jobs | List all jobs in a pipeline |
| gitlab_get_job_log | Get job logs with tail and keyword search |
| gitlab_play_job | Trigger a manual job |
| gitlab_retry_job | Retry a failed job |
Prerequisites
- A GitLab instance (self-hosted or gitlab.com)
- A Personal Access Token with
apiscope- GitLab → Settings → Access Tokens → New Token
Quick Start (npx)
No installation needed — just configure your MCP client:
{
"mcpServers": {
"gitlab": {
"command": "npx",
"args": ["-y", "gitlab-ci-mcp-server"],
"env": {
"GITLAB_URL": "https://gitlab.example.com",
"GITLAB_TOKEN": "glpat-xxxxxxxxxxxxxxxxxxxx",
"GITLAB_PROJECT_ID": "12345"
}
}
}
}Environment Variables
| Variable | Required | Description |
|----------|----------|-------------|
| GITLAB_URL | Yes | GitLab instance URL (e.g. https://gitlab.com) |
| GITLAB_TOKEN | Yes | Personal Access Token with api scope |
| GITLAB_PROJECT_ID | Yes | Numeric project ID (found on project homepage) |
MCP Client Configuration
Kiro
Add to .kiro/settings/mcp.json:
{
"mcpServers": {
"gitlab": {
"command": "npx",
"args": ["-y", "gitlab-ci-mcp-server"],
"env": {
"GITLAB_URL": "https://gitlab.example.com",
"GITLAB_TOKEN": "your-token",
"GITLAB_PROJECT_ID": "12345"
}
}
}
}Claude Desktop
Add to Claude Desktop config (claude_desktop_config.json):
{
"mcpServers": {
"gitlab": {
"command": "npx",
"args": ["-y", "gitlab-ci-mcp-server"],
"env": {
"GITLAB_URL": "https://gitlab.example.com",
"GITLAB_TOKEN": "your-token",
"GITLAB_PROJECT_ID": "12345"
}
}
}
}Cursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"gitlab": {
"command": "npx",
"args": ["-y", "gitlab-ci-mcp-server"],
"env": {
"GITLAB_URL": "https://gitlab.example.com",
"GITLAB_TOKEN": "your-token",
"GITLAB_PROJECT_ID": "12345"
}
}
}
}Local Development
git clone <repo-url>
cd gitlab-ci-mcp-server
npm install
npm run build
npm startLicense
MIT
