YP

yshngg/prometheus-mcp-server

Developer tools

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

5 stars 5 forks 품질 74 트렌드 27Apache-2.0

A Prometheus Model Context Protocol Server.

개요

A Go-based MCP server that exposes Prometheus query capabilities via the Model Context Protocol. All flags can be set via environment variables: PROM_ADDR, MCP_ADDR, TRANSPORT, AUTH_TOKEN. Add the following config to your MCP client: Install the binary via go install github.com/yshngg/prometheus-mcp-server@latest or pull the Docker image with docker pull ghcr.io/yshngg/prometheus-mcp-server:latest. If you don't have the binary installed, use Docker: Then configure your client to use http://localhost:8080/mcp. For authenticated access, set AUTH_TOKEN: Your client must then include Authorization: Bearer my-token in requests to /mcp.

README

원문 README의 일부입니다. 원문 보기.

Prometheus MCP Server

A Go-based MCP server that exposes Prometheus query capabilities via the Model Context Protocol.

Installation

go install github.com/yshngg/prometheus-mcp-server@latest

Or pull the Docker image:

docker pull ghcr.io/yshngg/prometheus-mcp-server:latest

Usage

prometheus-mcp-server --prom-addr="http://localhost:9090"

Flags

Flag Default Description
-prom-addr http://localhost:9090 Prometheus server URL
-mcp-addr localhost:8080 MCP server listen address
-transport stdio stdio or http
-auth-token `` Bearer token for MCP endpoint authentication (optional)
-version Print version

Environment Variables

All flags can be set via environment variables: PROM_ADDR, MCP_ADDR, TRANSPORT, AUTH_TOKEN.

MCP Client Configuration

Add the following config to your MCP client:

{
  "mcpServers": {
    "prometheus": {
      "command": "prometheus-mcp-server",
      "args": ["--prom-addr", "http://localhost:9090"]
    }
  }
}

[!NOTE] Install the binary via go install github.com/yshngg/prometheus-mcp-server@latest or pull the Docker image with docker pull ghcr.io/yshngg/prometheus-mcp-server:latest.

If you don’t have the binary installed, use Docker:

{
  "mcpServers": {
    "prometheus": {
      "command": "docker",
      "args": [
        "run",
        "--rm",
        "-i",
        "ghcr.io/yshngg/prometheus-mcp-server:latest",
        "--prom-addr",
        "http://host.docker.internal:9090"
      ]
    }
  }
}

Client-specific configuration

Add to opencode.json (guide):

{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "prometheus": {
      "type": "local",
      "command": [
GitHub에서 전체 README 보기

설치

docker run --rm -i ghcr.io/yshngg/prometheus-mcp-server:latest --prom-addr http://host.docker.internal:9090
MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →

설정

{ "mcpServers": { "prometheus": { "command": "prometheus-mcp-server", "args": ["--prom-addr", "http://localhost:9090"] } } }