Skip to content

WIP: openshift-mcp-server: add mcpchecker eval job for Google Gemini - #78018

Closed
matzew wants to merge 1 commit into
openshift:mainfrom
matzew:evals_mcp_server
Closed

WIP: openshift-mcp-server: add mcpchecker eval job for Google Gemini#78018
matzew wants to merge 1 commit into
openshift:mainfrom
matzew:evals_mcp_server

Conversation

@matzew

@matzew matzew commented Apr 20, 2026

Copy link
Copy Markdown
Member

Add an optional, always-run presubmit job that runs mcpchecker evaluations using Google Gemini against the MCP server. The job will fail until Vault credentials are wired in a follow-up PR.

Summary by CodeRabbit

  • Tests
    • Added a new Google Gemini-based Kubernetes evaluation test workflow to the CI pipeline
    • The evaluation test can be triggered using the /test mcpchecker-eval-google command in pull requests

Add an optional, always-run presubmit job that runs mcpchecker
evaluations using Google Gemini against the MCP server. The job
will fail until Vault credentials are wired in a follow-up PR.

Signed-off-by: Matthias Wessendorf <mwessend@redhat.com>
@openshift-ci openshift-ci Bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Apr 20, 2026
@coderabbitai

coderabbitai Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

Walkthrough

Two CI configuration files are updated to add a new optional test workflow step for evaluating the MCP server using mcpchecker with Google Gemini-based Kubernetes assessment. The workflow includes building, installing mcpchecker, running the server, executing the evaluation, and cleanup.

Changes

Cohort / File(s) Summary
MCP Server Evaluation Test Workflow
ci-operator/config/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main.yaml
Adds new optional test step mcpchecker-eval-google that builds the project, installs mcpchecker, starts the MCP server with core and config toolsets, runs Kubernetes evaluation against Google Gemini model, and stops the server with failure tolerance.
Prow Presubmit Job Configuration
ci-operator/jobs/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main-presubmits.yaml
Adds new presubmit job pull-ci-openshift-openshift-mcp-server-main-mcpchecker-eval-google configured for branch main, running on build03 cluster as an optional always-run test, with Prow orchestration and test command trigger support.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

🚥 Pre-merge checks | ✅ 10
✅ Passed checks (10 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: adding a new mcpchecker evaluation job for Google Gemini to the openshift-mcp-server CI configuration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Stable And Deterministic Test Names ✅ Passed PR modifies CI/CD configuration YAML files only, not Ginkgo test code. No Ginkgo test definitions present.
Test Structure And Quality ✅ Passed PR modifies CI/CD configuration files in YAML format, not Go test code or Ginkgo tests, so the custom check is not applicable.
Microshift Test Compatibility ✅ Passed PR contains only CI/Prow configuration YAML files with no new Ginkgo e2e tests, so custom check is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed This PR does not add any Ginkgo e2e tests; it only modifies CI/CD YAML configuration files, so the check is not applicable and passes.
Topology-Aware Scheduling Compatibility ✅ Passed PR modifies CI/CD infrastructure configuration files (ci-operator and Prow job definitions), not deployment manifests, operator code, or controllers with scheduling constraints.
Ote Binary Stdout Contract ✅ Passed The OTE Binary Stdout Contract check is not applicable to this pull request. The PR only modifies CI configuration YAML files, not Go source code.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed This PR does not add any Ginkgo e2e tests. The changes are purely CI/CD configuration files (YAML) that define a new test workflow step and presubmit job for running mcpchecker evaluations. The custom check specifically applies to when new Ginkgo e2e tests are added (It(), Describe(), Context(), When(), etc.) — since no Ginkgo tests are present in this PR, the check is not applicable and passes by default.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci

openshift-ci Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: matzew

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 20, 2026
@matzew

matzew commented Apr 20, 2026

Copy link
Copy Markdown
Member Author

/assign @mvinkler
/assign @Cali0707

DRAFTING an initial hook. For prow/downstream evals.

Yet, I have to understand the vault situation. and how to get the API Key for usage there, and how to consume.

But starting the game w/ a DRAFTED version of a simplified first job.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

[REHEARSALNOTIFIER]
@matzew: the pj-rehearse plugin accommodates running rehearsal tests for the changes in this PR. Expand 'Interacting with pj-rehearse' for usage details. The following rehearsable tests have been affected by this change:

Test name Repo Type Reason
pull-ci-openshift-openshift-mcp-server-main-mcpchecker-eval-google openshift/openshift-mcp-server presubmit Presubmit changed

Prior to this PR being merged, you will need to either run and acknowledge or opt to skip these rehearsals.

Interacting with pj-rehearse

Comment: /pj-rehearse to run up to 5 rehearsals
Comment: /pj-rehearse skip to opt-out of rehearsals
Comment: /pj-rehearse {test-name}, with each test separated by a space, to run one or more specific rehearsals
Comment: /pj-rehearse more to run up to 10 rehearsals
Comment: /pj-rehearse max to run up to 25 rehearsals
Comment: /pj-rehearse auto-ack to run up to 5 rehearsals, and add the rehearsals-ack label on success
Comment: /pj-rehearse list to get an up-to-date list of affected jobs
Comment: /pj-rehearse abort to abort all active rehearsals
Comment: /pj-rehearse network-access-allowed to allow rehearsals of tests that have the restrict_network_access field set to false. This must be executed by an openshift org member who is not the PR author

Once you are satisfied with the results of the rehearsals, comment: /pj-rehearse ack to unblock merge. When the rehearsals-ack label is present on your PR, merge will no longer be blocked by rehearsals.
If you would like the rehearsals-ack label removed, comment: /pj-rehearse reject to re-block merging.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@ci-operator/config/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main.yaml`:
- Around line 50-62: The CI invokes non-existent Makefile targets make
run-server and make stop-server; replace them with the repository's actual
pattern by either calling the existing local-env-setup/local-env-teardown
targets or directly starting/stopping the built server binary
(kubernetes-mcp-server) with the correct flags (e.g., --port and --config) used
elsewhere; update the steps that reference make run-server TOOLSETS=core,config
and make stop-server to instead call local-env-setup/local-env-teardown or
run/kill the kubernetes-mcp-server process so the job no longer fails with "No
rule to make target 'run-server'".
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 47b53008-7a8a-449d-9d67-101387cd418a

📥 Commits

Reviewing files that changed from the base of the PR and between a8a94b5 and eabb266.

📒 Files selected for processing (2)
  • ci-operator/config/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main.yaml
  • ci-operator/jobs/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main-presubmits.yaml

Comment on lines +50 to +62
# Start MCP server in background (no cluster needed for this step)
make run-server TOOLSETS=core,config

# Run mcpchecker evaluation with Google Gemini agent
# NOTE: This will fail until Vault credentials are wired (follow-up PR)
_output/tools/bin/mcpchecker check \
evals/core-eval-testing/builtin-google/eval-kubernetes.yaml \
--label-selector suite=kubernetes \
--output json \
|| true

# Cleanup
make stop-server || true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify whether run-server / stop-server targets in the openshift-mcp-server Makefile
# detach the server (e.g., via & or nohup) or run in foreground.
gh api repos/openshift/openshift-mcp-server/contents/Makefile --jq '.content' \
  | base64 -d \
  | awk '/^run-server:|^stop-server:|^mcpchecker:/{flag=1} flag{print} /^$/{flag=0}'

Repository: openshift/release

Length of output: 43


🏁 Script executed:

# Search for Makefile in the repository that was configured
# First, check if there's an openshift-mcp-server reference or Makefile in the release repo
find . -name "Makefile" -type f | grep -E "(mcp|server)" | head -20

Repository: openshift/release

Length of output: 43


🏁 Script executed:

# Also search the YAML file's directory for context about how the server is invoked
cd ci-operator/config/openshift/openshift-mcp-server/ 2>/dev/null && ls -la && head -100 openshift-openshift-mcp-server-main.yaml

Repository: openshift/release

Length of output: 2781


🌐 Web query:

openshift-mcp-server Makefile run-server target backgrounding process

💡 Result:

The openshift-mcp-server repository's main Makefile does not contain a 'run-server' target. The Makefile provides targets like 'build', 'test', 'clean', 'local-env-setup', etc., for building the kubernetes-mcp-server binary and setting up local development (e.g., Kind cluster). Running the server is done directly with the built binary: ./kubernetes-mcp-server [--port 8008] [--config _output/config.toml]. No backgrounding (&, nohup) is used in the Makefile; servers are typically run in the foreground for development or as container ENTRYPOINT/CMD in Dockerfiles (e.g., CMD ["--port", "8080"]). For OpenShift builds, Dockerfile.ocp uses 'make -f Makefile-ocp.mk build-ocp', but no run-server target is evident. In container deployments on OpenShift, processes run in foreground as PID 1.

Citations:


🏁 Script executed:

# Search the openshift/release repo for references to run-server and stop-server
rg "run-server|stop-server" --type yaml -B 2 -A 2 | head -50

Repository: openshift/release

Length of output: 1215


🏁 Script executed:

# Check if there are multiple Makefiles or build files
git ls-files | grep -iE "(makefile|make)" | head -20

Repository: openshift/release

Length of output: 699


🌐 Web query:

openshift-mcp-server Makefile "run-server" OR "stop-server" target definition

💡 Result:

No "run-server" or "stop-server" targets are defined in the Makefile of the openshift-mcp-server repository (https://github.com/openshift/openshift-mcp-server). The Makefile includes standard targets like help, clean, build, test, format, tidy, local-env-setup, and local-env-teardown, but nothing matching "run-server" or "stop-server". The server is run directly via the built binary, e.g., ./kubernetes-mcp-server --port 8008 --config _output/config.toml as shown in local-env-setup output. A separate Makefile-ocp.mk exists for OCP builds, referenced in Dockerfile.ocp, but no evidence of those targets there either. "openshift-mcp-server" is a recent (2025) fork for Model Context Protocol (MCP), unrelated to legacy Machine Config Pool server.

Citations:


make run-server and make stop-server targets do not exist in the openshift-mcp-server Makefile.

The CI job invokes make run-server TOOLSETS=core,config and make stop-server, but these targets are not defined in the repository's Makefile or Makefile-ocp.mk. The Makefile contains standard targets like build, test, clean, local-env-setup, and local-env-teardown, but nothing matching "run-server" or "stop-server". The server is run directly via the built binary (e.g., ./kubernetes-mcp-server --port 8008 --config _output/config.toml). This job will fail immediately with "No rule to make target 'run-server'". Confirm the correct invocation pattern with the repository maintainers and update the commands to match the actual Makefile or direct binary invocation.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@ci-operator/config/openshift/openshift-mcp-server/openshift-openshift-mcp-server-main.yaml`
around lines 50 - 62, The CI invokes non-existent Makefile targets make
run-server and make stop-server; replace them with the repository's actual
pattern by either calling the existing local-env-setup/local-env-teardown
targets or directly starting/stopping the built server binary
(kubernetes-mcp-server) with the correct flags (e.g., --port and --config) used
elsewhere; update the steps that reference make run-server TOOLSETS=core,config
and make stop-server to instead call local-env-setup/local-env-teardown or
run/kill the kubernetes-mcp-server process so the job no longer fails with "No
rule to make target 'run-server'".

@openshift-ci

openshift-ci Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

@matzew: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/ci-operator-config-metadata eabb266 link true /test ci-operator-config-metadata

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@matzew

matzew commented Aug 19, 2026

Copy link
Copy Markdown
Member Author

/close

@openshift-ci openshift-ci Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 19, 2026
@openshift-ci

openshift-ci Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

PR needs rebase.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@openshift-ci openshift-ci Bot closed this Aug 19, 2026
@openshift-ci

openshift-ci Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

@matzew: Closed this PR.

Details

In response to this:

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants