Skip to main content
Glama
jenkins-http-mcp-server

jenkins-http-mcp-server

Jenkins MCP 서버

Jenkins 2.563을 위한 외부 Python MCP 서버입니다. JENKINS_USER 및 JENKINS_API_TOKEN에 부여된 권한을 사용하여 일반 Jenkins HTTP API를 통해 연결합니다.

Jenkins 관리자 권한이 필요하지 않으며, Jenkins 플러그인을 설치하지 않고, 공식 Jenkins MCP 서버 플러그인에 의존하지 않습니다.

Python 설정

이 프로젝트는 로컬에서 사용 가능한 최신 안정 버전인 Python 3.14.x를 사용하여 pyenv로 초기화되었습니다:

  • Python: 3.14.4

  • pyenv virtualenv: venv3144

재현 방법:

pyenv local venv3144
python --version
which python
pyenv version

Related MCP server: Jenkins MCP Server

설치

python -m pip install -e '.[dev]'

환경

필수:

export JENKINS_URL="https://jenkins.example.com/"
export JENKINS_USER="your-user"
export JENKINS_API_TOKEN="your-api-token"

선택 사항:

export JENKINS_VERIFY_SSL=1
export JENKINS_TIMEOUT_SECONDS=30
export JENKINS_MCP_MAX_RESPONSE_BYTES=2000000
export JENKINS_MCP_MAX_LOG_BYTES=200000

쓰기 게이트:

export JENKINS_MCP_ENABLE_WRITES=1
export JENKINS_MCP_ENABLE_JOB_CONFIG_WRITE=1
export JENKINS_MCP_ENABLE_DELETE=1

MCP 클라이언트 구성 파일에 실제 Jenkins 비밀 정보를 저장하지 마십시오.

STDIO 서버 실행

python -m jenkins_mcp_server

콘솔 스크립트:

jenkins-mcp-server

클라이언트 설정

  • Codex CLI: docs/codex-setup.md

  • Gemini CLI: docs/gemini-setup.md

도구

읽기 전용:

  • jenkins_whoami

  • jenkins_version

  • jenkins_health

  • jenkins_get_json

  • jenkins_list_jobs

  • jenkins_get_job

  • jenkins_get_job_config

  • jenkins_list_builds

  • jenkins_get_build

  • jenkins_get_build_log

  • jenkins_get_build_artifacts

  • jenkins_get_test_report

  • jenkins_list_queue

  • jenkins_get_queue_item

  • jenkins_list_views

  • jenkins_get_view

  • jenkins_list_nodes

  • jenkins_get_node

  • jenkins_list_plugins

쓰기 도구 (JENKINS_MCP_ENABLE_WRITES=1로 제어):

  • jenkins_trigger_build

  • jenkins_trigger_build_with_parameters

  • jenkins_stop_build

  • jenkins_cancel_queue_item

  • jenkins_enable_job

  • jenkins_disable_job

선택적 작업 구성 도구 (JENKINS_MCP_ENABLE_WRITES=1 및 JENKINS_MCP_ENABLE_JOB_CONFIG_WRITE=1로 제어):

  • jenkins_create_job

  • jenkins_copy_job

  • jenkins_update_job_config

삭제 기능은 추가로 JENKINS_MCP_ENABLE_DELETE=1이 필요합니다:

  • jenkins_delete_job

안전성

  • 기본적으로 읽기 전용입니다.

  • 쓰기 도구는 명시적인 로컬 환경 플래그와 Jenkins 측 권한이 필요합니다.

  • Jenkins 로그 및 작업 출력은 신뢰할 수 없는 텍스트로 취급됩니다.

  • API 토큰 및 인증 헤더는 서버 도우미에 의해 출력되지 않습니다.

  • 401, 403, 404, crumb 오류 및 권한 오류는 구조화된 오류를 반환합니다.

제한 사항

  • 스크립트 콘솔 없음.

  • 재시작, 안전한 재시작 또는 조용히 하기(quiet down) 기능 없음.

  • 플러그인 설치/업데이트 없음.

  • 자격 증명 읽기/쓰기 없음.

  • 노드 생성/삭제 없음.

  • 전역 구성 변경 없음.

  • 사용자 관리 없음.

  • jenkins_get_test_report는 testReport를 노출하는 JUnit과 같은 테스트 보고서 플러그인에 의존하며, 없을 경우 명확하게 실패합니다.

  • 중첩된 폴더 경로는 URL 인코딩되어 반복되는 job/<segment> 경로 구성 요소로 처리됩니다. 필요한 폴더/작업 유형이 없는 컨트롤러는 Jenkins 404를 반환합니다.

테스트

일반 테스트는 모의(mock) 처리되며 라이브 Jenkins 컨트롤러가 필요하지 않습니다:

python -m pytest
python -m compileall src
ruff check

선택적 통합 테스트는 모든 설정이 완료된 경우에만 실행됩니다:

export JENKINS_INTEGRATION_TESTS=1
export JENKINS_URL="https://jenkins.example.com/"
export JENKINS_USER="your-user"
export JENKINS_API_TOKEN="your-api-token"
python -m pytest tests/test_integration.py

증거 문서

  • docs/source-truth.md

  • docs/source-skills-check.md

  • docs/existing-research.md

  • docs/architecture-decision.md

  • docs/tool-evidence.md

  • docs/security.md

Available Tools

40 tools
jenkins_cancel_artifact_downloadA
Destructive

Request cancellation of a running artifact download.

Inputs: operation_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_cancel_queue_itemA
Destructive

Cancel a Jenkins queue item. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: item_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_cancel_workspace_bundle_downloadB
Destructive

Request cancellation of a running workspace bundle operation.

Inputs: operation_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_cleanup_workspace_bundle_operationsA
Destructive

Delete bounded, terminal local workspace operations older than the requested age.

Inputs: max_operations, older_than_days. Returns: Structured content returned by successful Jenkins tools.

jenkins_copy_jobB

Copy a top-level job. Requires write and job-config flags.

Inputs: from_job (required), new_name (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_create_jobA

Create a top-level job from config.xml. Requires write and job-config flags.

Inputs: name (required), config_xml (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_delete_jobA
Destructive

Delete a job. Requires write, job-config, and delete flags.

Inputs: job (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_disable_jobB
Destructive

Disable a job. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: job (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_enable_jobA
Destructive

Enable a job. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: job (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_artifact_download_statusC
Destructive

Get artifact download bytes, speed, paths, and final status.

Inputs: operation_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_buildA
Read-only

Get a build by number or Jenkins permalink such as lastBuild.

Inputs: job (required), build (required), tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_get_build_artifactsB
Read-only

List artifacts exported on a build JSON API response.

Inputs: job (required), build (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_build_logA
Read-only

Get consoleText for a build, truncated by JENKINS_MCP_MAX_LOG_BYTES.

Inputs: job (required), build (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_build_log_chunkA
Read-only

Read one progressive log response and return Jenkins' next safe cursor.

Inputs: job (required), build (required), start. Returns: Structured content returned by successful Jenkins tools.

jenkins_get_jobA
Read-only

Get one job by Jenkins job path. Nested paths use slash-separated names or a list.

Inputs: job (required), tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_get_job_configA
Read-only

Read serialized job config.xml; secrets may be redacted without Configure permission.

Inputs: job (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_jsonB
Read-only

GET a relative Jenkins JSON API path. Rejects external URLs and traversal.

Inputs: path (required), query. Returns: Structured content returned by successful Jenkins tools.

jenkins_get_nodeA
Read-only

Get one Jenkins computer/node by name. Use (built-in) for the built-in node.

Inputs: node (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_queue_itemA
Read-only

Get one Jenkins queue item by ID.

Inputs: item_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_test_reportA
Read-only

Get /testReport/api/json when a test-report plugin such as JUnit provides it.

Inputs: job (required), build (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_viewA
Read-only

Get one Jenkins view by name.

Inputs: view (required), tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_get_workspace_bundle_statusB
Destructive

Get download/extract/log progress, bytes, speed, paths, and final status.

Inputs: operation_id (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_get_workspace_treeA
Read-only

List a bounded live workspace tree. Paths are not bound to a build number.

Inputs: job (required), max_depth, max_entries, workspace_path. Returns: Structured content returned by successful Jenkins tools.

jenkins_healthA
Read-only

Return a small health snapshot from top-level Jenkins JSON and version headers.

Inputs: no named parameters. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_buildsA
Read-only

List recent builds for a job.

Inputs: job (required), tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_jobsB
Read-only

List jobs visible to the Jenkins user.

Inputs: tree, depth. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_nodesA
Read-only

List Jenkins computers/nodes visible to the user.

Inputs: tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_pluginsB
Read-only

List installed Jenkins plugins visible through pluginManager/api/json.

Inputs: tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_queueB
Read-only

List visible Jenkins queue items.

Inputs: tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_list_viewsB
Read-only

List Jenkins views visible to the user.

Inputs: tree. Returns: Structured content returned by successful Jenkins tools.

jenkins_search_build_logA
Read-only

Stream and search bounded consoleText for an exact, case-sensitive literal.

Inputs: job (required), build (required), pattern (required), max_matches, +1 more. Returns: Structured content returned by successful Jenkins tools.

jenkins_start_artifact_downloadB

Start a gated async download of one archived build artifact to local disk.

Inputs: job (required), artifact_path (required), build. Returns: Structured content returned by successful Jenkins tools.

jenkins_start_workspace_bundle_downloadC
Destructive

Start or join a guarded workspace capture plus exact build console log.

Inputs: job (required), build, force_refresh. Returns: Structured content returned by successful Jenkins tools.

jenkins_start_workspace_path_downloadC
Destructive

Start or join a guarded workspace file/folder capture plus exact console log.

Inputs: job (required), kind (required), workspace_path (required), build, +1 more. Returns: Structured content returned by successful Jenkins tools.

jenkins_stop_buildB
Destructive

Stop a running build. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: job (required), build (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_trigger_buildA
Destructive

Trigger a non-parameterized job build. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: job (required), delay. Returns: Structured content returned by successful Jenkins tools.

jenkins_trigger_build_with_parametersA
Destructive

Trigger a parameterized job build. Requires JENKINS_MCP_ENABLE_WRITES=1.

Inputs: job (required), parameters (required), delay. Returns: Structured content returned by successful Jenkins tools.

jenkins_update_job_configA
Destructive

Replace job config.xml; Jenkins reserializes it. Requires job-config write gates.

Inputs: job (required), config_xml (required). Returns: Structured content returned by successful Jenkins tools.

jenkins_versionA
Read-only

Return Jenkins version from the X-Jenkins response header.

Inputs: no named parameters. Returns: Structured content returned by successful Jenkins tools.

jenkins_whoamiA
Read-only

Return the authenticated Jenkins identity from /whoAmI/api/json.

Inputs: no named parameters. Returns: Structured content returned by successful Jenkins tools.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.3/5.0

    Scored across 40 tools

    Disambiguation4/5

    Most tools map cleanly to a distinct resource and action, such as list_jobs, get_build, trigger_build, delete_job. A few boundary cases—generic get_json versus named getters, the three build-log retrieval tools, and the workspace/artifact download variants—could cause mnisselection but are resolvable from descriptions.

    Naming Consistency4/5

    All tools share the jenkins_ prefix and use snake_case, with a mostly consistent verb_noun pattern: list_jobs, get_job, trigger_build, delete_job, cancel_queue_item. Minor deviations such as jenkins_version, jenkins_health, and jenkins_whoami being noun-only or nonstandard keep it from a perfect 5.

    Tool Count2/5

    40 tools is well above the 25+ threshold for a bloated tool surface. While Jenkins is a large domain, many of these could be consolidated—particularly the multiple download/status/cancel/cleanup bundles—making the set feel heavier than necessary for an MCP server.

    Completeness4/5

    The set covers core Jenkins workflows well: job create/read/update/delete/enable/disable, build trigger/stop/log/artifacts/test reports, queue management, and workspace/artifact retrieval. Minor gaps exist—node and view management are read-only, and there is no credential or plugin administration—but the generic get_json tool helps fill some edge cases.

    Maintenance

    ActivityNo data
    ResponsivenessSyncing

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with Jenkins to manage jobs, trigger builds with parameters, and monitor build queues. It provides comprehensive access to build histories, console logs, and organizational folder structures via the Jenkins REST API.
      1
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with Jenkins instances to manage jobs, builds, and nodes through the Model Context Protocol. It provides capabilities to trigger builds, read console outputs, and search log sections using regular expressions.
      ISC