Описание
MCP Server for Kruize
README
A cloud-native MCP server designed to act as a bridge between AI models/Agentic workflows and the Kruize recommendations engine. Kruize MCP server exposes Kubernetes resource recommendation data, including idle workload detection, as simple, actionable tools for AI models.
Quick Start
Choose your platform:
OpenShift
Deploy
# 1. Clone and build
git clone https://github.com:kruize/kruize-mcp-server.git
cd kruize-mcp-server
./mvnw install
# 2. Deploy Kruize
./local_monitoring_demo.sh -c openshift -e container
# 3. Build and push image
docker build -t <registry>/<username>/kruize-mcp-server:<tag> .
docker push <registry>/<username>/kruize-mcp-server:<tag>
# 4. Deploy MCP server (in openshift-tuning namespace)
oc apply -f manifests/kruize-mcp-server-openshift.yaml -n openshift-tuning
oc expose service kruize-mcp-server-service -n openshift-tuning
# 5. Get URL and connect Inspector
oc get route kruize-mcp-server-service -n openshift-tuning --template='{{ .spec.host }}'
npx @modelcontextprotocol/inspector http://<route-url>/mcp/
Deployment Location: openshift-tuning namespace (same as Kruize)
Minikube
Deploy
# 1. Clone
git clone https://github.com:kruize/kruize-mcp-server.git
cd kruize-mcp-server
# 2. Deploy Kruize (sets up Minikube + Prometheus)
git clone https://github.com/kruize/kruize-demos.git
cd kruize-demos/monitoring/local_monitoring
./local_monitoring_demo.sh -c minikube -f -e container
# 3. Get Kruize connection details
# Get Kruize URL (Minikube IP + NodePort)
KRUIZE_URL=$(echo "http://$(minikube ip):$(kubectl get svc kruize -n monitoring -o jsonpath='{.spec.ports[0].nodePort}')")
echo "Kruize URL: $KRUIZE_URL"
# 4. Deploy MCP server
cd kruize-mcp-server
# Update the KRUIZE_URL in the manifest file with the value from above
# Edit manifests/kruize-mcp-server-minikube.yaml and replace <minikube-ip>:<kruize-port> with the actual URL
kubectl apply -f manifests/kruize-mcp-server-minikube.yaml
kubectl wait --for=condition=ready pod -l app=kruize-mcp-server -n monitoring --timeout=120s
# 5. Port forward and connect Inspector
kubectl port-forward -n monitoring service/kruize-mcp-server-service 8082:8082
npx @modelcontextprotocol/inspector http://localhost:8082/mcp/
Note: Kruize MCP server uses port 8082 (Kruize uses 8080/8081)
Important: After connecting with Inspector tool, verify the URL matches your deployment in the Inspector tool UI:
- OpenShift: Use the MCP server route URL from
oc get route kruize-mcp-server-service -n openshift-tuning - Minikube: Use
http://localhost:8082/mcp/(after port-forward) - Local JAR: Use
http://localhost:8080/mcp/orhttp://localhost:8082/mcp/depending on configuration
MCP Tools
listAllExperiments- List all experimentslistAllRecommendations- List resource optimization CPU/memory recommendations for all the containersgetCostOptimizedRecommendations- Get cost-optimized CPU/memory recommendations for a container. Optionally by namespacegetPerformanceRecommendations- Get performance-optimized CPU/memory recommendations for a container. Optionally by namespacegetIdleWorkloads- Get idle workloads (CPU usage < 1 millicore). Optionally with cost and performance recommendations
Local Development
Run from JAR - OpenShift Configuration
# 1. Build the project
./mvnw clean install
# 2. Get your Kruize route URL
KRUIZE_URL=$(oc get route kruize -n openshift-tuning --template='http://{{ .spec.host }}')
echo "Kruize URL: $KRUIZE_URL"
# 3. Run the JAR file with Kruize URL (port 8080)
KRUIZE_URL=$KRUIZE_URL java -jar target/kruize-mcp-server-1.0-SNAPSHOT-runner.jar
# 4. Connect Inspector
npx @modelcontextprotocol/inspector http://localhost:8080/mcp/
Custom Kruize URL (if needed):
# Replace with your actual Kruize route URL
KRUIZE_URL=http://kruize-openshift-tuning.apps.your-cluster.com java -jar target/kruize-mcp-server-1.0-SNAPSHOT-runner.jar
Run from JAR - Minikube Configuration
# 1. Build the project
./mvnw clean install
# 2. Get Kruize URL (Minikube IP + NodePort)
KRUIZE_URL=$(echo "http://$(minikube ip):$(kubectl get svc kruize -n monitoring -o jsonpath='{.spec.ports[0].nodePort}')")
echo "Kruize URL: $KRUIZE_URL"
# 3. Run the JAR file (port 8082 to avoid conflict with Kruize on 8080/8081)
QUARKUS_HTTP_PORT=8082 KRUIZE_URL=$KRUIZE_URL java -jar target/kruize-mcp-server-1.0-SNAPSHOT-runner.jar
# 4. Connect Inspector
npx @modelcontextprotocol/inspector http://localhost:8082/mcp/
Custom Kruize URL (if needed):
# Replace with your actual Kruize URL
QUARKUS_HTTP_PORT=8082 KRUIZE_URL=http://192.168.49.2:30080 java -jar target/kruize-mcp-server-1.0-SNAPSHOT-runner.jar
Health Check API
The server includes comprehensive health check endpoints for monitoring and Kubernetes integration:
Quick Test
# Test health endpoints (default port)
curl http://localhost:8080/q/health # Overall health
curl http://localhost:8080/q/health/live # Liveness probe
curl http://localhost:8080/q/health/ready # Readiness probe
# Test with custom URL
curl http://localhost:8082/q/health # Custom port
curl https://kruize-mcp.example.com/q/health # Remote server
Health Endpoints
/q/health- Overall health status (aggregates all checks)/q/health/live- Liveness probe (triggers pod restart on failure)/q/health/ready- Readiness probe (removes pod from service on failure)
Kubernetes Integration
Health probes are automatically configured in the Kubernetes manifests:
- Liveness Probe: Checks every 30s, restarts pod on failure
- Readiness Probe: Checks every 10s, removes from service on failure
Both probes verify Kruize API connectivity to ensure the service is operational.
Documentation
- Health Check API Guide - Complete API reference
Установка Kruize
У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.
▸ github.com/kruize/kruize-mcp-serverFAQ
Kruize MCP бесплатный?
Да, Kruize MCP бесплатный — установка в пару кликов через Unyly без оплаты.
Нужен ли API-ключ для Kruize?
Нет, Kruize работает без API-ключей и переменных окружения.
Kruize — hosted или self-hosted?
Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.
Как установить Kruize в Claude Desktop, Claude Code или Cursor?
Открой Kruize на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.
Похожие MCP
GitHub
PRs, issues, code search, CI status
автор: GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
автор: mcpdotdirectCompare Kruize with
Не уверен что выбрать?
Найди свой стек за 60 секунд
Автор?
Embed-бейдж для README
Похожее
Все в категории development
