Commit Graph

415 Commits

Author SHA1 Message Date
Matthias Wessendorf
d94d72d902 upstream<carry>: Downstream 2025-10-07 09:50:51 +02:00
Matthias Wessendorf
ee93bb08b8 Merge remote-tracking branch 'downstream/main' into sync-downstream 2025-10-07 09:48:39 +02:00
openshift-merge-bot[bot]
f76474cd46 Merge pull request #37 from openshift/konflux/references/main
chore(deps): update konflux references main
2025-10-07 06:43:32 +00:00
dependabot[bot]
e8ba1fa0bf build(deps): bump github.com/go-jose/go-jose/v4 from 4.1.2 to 4.1.3 (#357)
Bumps [github.com/go-jose/go-jose/v4](https://github.com/go-jose/go-jose) from 4.1.2 to 4.1.3.
- [Release notes](https://github.com/go-jose/go-jose/releases)
- [Commits](https://github.com/go-jose/go-jose/compare/v4.1.2...v4.1.3)

---
updated-dependencies:
- dependency-name: github.com/go-jose/go-jose/v4
  dependency-version: 4.1.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-06 12:06:46 +02:00
dependabot[bot]
e86d314ae2 build(deps): bump github.com/coreos/go-oidc/v3 from 3.15.0 to 3.16.0 (#356)
Bumps [github.com/coreos/go-oidc/v3](https://github.com/coreos/go-oidc) from 3.15.0 to 3.16.0.
- [Release notes](https://github.com/coreos/go-oidc/releases)
- [Commits](https://github.com/coreos/go-oidc/compare/v3.15.0...v3.16.0)

---
updated-dependencies:
- dependency-name: github.com/coreos/go-oidc/v3
  dependency-version: 3.16.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-06 12:06:42 +02:00
Calum Murray
a2d16e9f41 feat: Multi Cluster Support (#348)
* feat: add cluster provider for kubeconfig

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: move server to use ClusterProvider interface

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: authentication middleware works with cluster provider

Signed-off-by: Calum Murray <cmurray@redhat.com>

* fix: unit tests work after cluster provider changes

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: add tool mutator to add cluster parameter

Signed-off-by: Calum Murray <cmurray@redhat.com>

* test: handle cluster parameter

Signed-off-by: Calum Murray <cmurray@redhat.com>

* fix: handle lazy init correctly

Signed-off-by: Calum Murray <cmurray@redhat.com>

* refactor: move to using multi-strategy ManagerProvider

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: add contexts_list tool

Signed-off-by: Calum Murray <cmurray@redhat.com>

* refactor: make tool mutator generic between cluster/context naming

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: introduce tool filter

Signed-off-by: Calum Murray <cmurray@redhat.com>

* refactor: use new ManagerProvider/mutator/filter within mcp server

Signed-off-by: Calum Murray <cmurray@redhat.com>

* fix(test): tests expect context parameter in tool defs

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: auth handles multi-cluster case correctly

Signed-off-by: Calum Murray <cmurray@redhat.com>

* fix: small changes from local testing

Signed-off-by: Calum Murray <cmurray@redhat.com>

* chore: fix enum test

Signed-off-by: Calum Murray <cmurray@redhat.com>

* review: Multi Cluster support (#1)

* nit: rename contexts_list to configuration_contexts_list

Besides the conventional naming, it helps LLMs understand the context of the tool by providing a certain level of hierarchy.

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* fix(mcp): ToolMutator doesn't rely on magic strings

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* refactor(api): don't expose ManagerProvider to toolsets

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* test(mcp): configuration_contexts_list basic tests

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* test(toolsets): revert edge-case test

This test should not be touched.

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* test(toolsets): add specific metadata tests for multi-cluster

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* fix(mcp): ToolFilter doesn't rely on magic strings (partially)

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* test(api): IsClusterAware and IsTargetListProvider default values

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* test(mcp): revert unneeded changes in mcp_tools_test.go

Signed-off-by: Marc Nuri <marc@marcnuri.com>

---------

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* fix: always include configuration_contexts_list if contexts > 1

Signed-off-by: Calum Murray <cmurray@redhat.com>

* feat: include server urls in configuration_contexts_list

Signed-off-by: Calum Murray <cmurray@redhat.com>

---------

Signed-off-by: Calum Murray <cmurray@redhat.com>
Signed-off-by: Marc Nuri <marc@marcnuri.com>
Co-authored-by: Marc Nuri <marc@marcnuri.com>
2025-10-06 12:01:16 +02:00
red-hat-konflux[bot]
100f369157 chore(deps): update konflux references main
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
2025-10-04 08:16:36 +00:00
Matthias Wessendorf
c447bf819f fix(auth): move 401 response handling to a common helper func (#353)
Signed-off-by: Matthias Wessendorf <mwessend@redhat.com>
2025-10-02 10:42:19 +02:00
dependabot[bot]
07b1ebc05e build(deps): bump github.com/mark3labs/mcp-go from 0.41.0 to 0.41.1 (#352)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go) from 0.41.0 to 0.41.1.
- [Release notes](https://github.com/mark3labs/mcp-go/releases)
- [Commits](https://github.com/mark3labs/mcp-go/compare/v0.41.0...v0.41.1)

---
updated-dependencies:
- dependency-name: github.com/mark3labs/mcp-go
  dependency-version: 0.41.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-01 09:14:30 +02:00
dependabot[bot]
adc1044615 build(deps): bump github.com/mark3labs/mcp-go from 0.40.0 to 0.41.0 (#349)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go) from 0.40.0 to 0.41.0.
- [Release notes](https://github.com/mark3labs/mcp-go/releases)
- [Commits](https://github.com/mark3labs/mcp-go/compare/v0.40.0...v0.41.0)

---
updated-dependencies:
- dependency-name: github.com/mark3labs/mcp-go
  dependency-version: 0.41.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-30 15:35:27 +02:00
openshift-merge-bot[bot]
7107a2474c Merge pull request #35 from openshift/konflux/references/main
chore(deps): update konflux references main
2025-09-30 08:56:49 +00:00
red-hat-konflux[bot]
bf57c06f86 chore(deps): update konflux references main
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
2025-09-27 08:12:28 +00:00
Marc Nuri
b55f28b36e feat(mcp): events_list returns parseable YAML output (#346)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-26 11:01:21 +02:00
Marc Nuri
d3723804ed chore(security): try to fix snyk security issues (#345)
* chore(docs): update tools in README.md

Previous update wasn't made automatically.

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* chore(security): try to fix snyk security issues

Even after the fix, Snyk seems to be reporting false positives.

Signed-off-by: Marc Nuri <marc@marcnuri.com>

---------

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-26 09:29:34 +02:00
Marc Nuri
792d2f5b80 chore(lint): fix linting issues (#344)
* chore(lint): fix linting issues

Signed-off-by: Marc Nuri <marc@marcnuri.com>

* feat(ci): add linting to build and build-all-platforms target

Signed-off-by: Marc Nuri <marc@marcnuri.com>

---------

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-26 06:56:48 +02:00
openshift-merge-bot[bot]
0959b36f39 Merge pull request #34 from ardaguclu/sync-downstream
NO-JIRA: Sync downstream with the latest changes in upstream
2025-09-25 14:04:01 +00:00
Arda Güçlü
45fac4ff35 Upstream<carry>: Update Dockerfile.ocp 2025-09-25 16:44:25 +03:00
Arda Güçlü
a9608d251a Upstream<drop>: Run go mod vendor 2025-09-25 16:40:49 +03:00
Arda Güçlü
459677365f Upstream<carry>: Add OCP specific configurations 2025-09-25 16:40:25 +03:00
Arda Güçlü
da152bcb50 Merge remote-tracking branch 'downstream/main' into sync-downstream 2025-09-25 16:35:55 +03:00
Marc Nuri
c69e90c70d fix(mcp): InputSchema schema with empty properties for no-arg tools (#341)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-25 11:54:07 +02:00
openshift-merge-bot[bot]
6c8de3b5d0 Merge pull request #32 from openshift/konflux/references/main
chore(deps): update konflux references main
2025-09-25 08:45:45 +00:00
red-hat-konflux[bot]
7137b67019 chore(deps): update konflux references main
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
2025-09-25 08:13:25 +00:00
iamsudip
053fb2e31c feat(pods): add optional tail parameter to pod logs retrieval (#335)
* feat(pods): add tailLines parameter to pod logs retrieval with default 256 lines

Signed-off-by: iamsudip <sudip.maji@harness.io>

* address review comments

Signed-off-by: iamsudip <sudip.maji@harness.io>

* test(pods): add tailLines parameter to pod logs retrieval with default 256 lines

Signed-off-by: Marc Nuri <marc@marcnuri.com>

---------

Signed-off-by: iamsudip <sudip.maji@harness.io>
Signed-off-by: Marc Nuri <marc@marcnuri.com>
Co-authored-by: Marc Nuri <marc@marcnuri.com>
2025-09-25 09:17:53 +02:00
openshift-merge-bot[bot]
47a3492d1d Merge pull request #33 from ralphbean/main-KONFLUX-6210-openshift-mcp-server
chore(KONFLUX-6210): fix and set name and cpe label for openshift-mcp-server
2025-09-25 05:52:19 +00:00
Ralph Bean
0181f6955a chore(KONFLUX-6210): fix and set name and cpe label for openshift-mcp-server
For https://issues.redhat.com/browse/KONFLUX-6210, clair needs access to a name and cpe label that it can use to look up the image in VEX statements.

See also release-engineering/rhtap-ec-policy#149

Signed-off-by: Ralph Bean <rbean@redhat.com>
Assisted-by: Gemini
2025-09-24 18:15:18 -04:00
dependabot[bot]
8e666d4c67 build(deps): bump github.com/google/jsonschema-go from 0.2.3 to 0.3.0 (#338)
Bumps [github.com/google/jsonschema-go](https://github.com/google/jsonschema-go) from 0.2.3 to 0.3.0.
- [Release notes](https://github.com/google/jsonschema-go/releases)
- [Commits](https://github.com/google/jsonschema-go/compare/v0.2.3...v0.3.0)

---
updated-dependencies:
- dependency-name: github.com/google/jsonschema-go
  dependency-version: 0.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-23 10:50:34 +02:00
Andrew Block
4c5bce1b65 feat(container): added non-privileged image user (#336)
Signed-off-by: Andrew Block <andy.block@gmail.com>
2025-09-22 10:30:15 +02:00
dependabot[bot]
2b72f5f9ab build(deps): bump github.com/mark3labs/mcp-go from 0.39.1 to 0.40.0 (#337)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go) from 0.39.1 to 0.40.0.
- [Release notes](https://github.com/mark3labs/mcp-go/releases)
- [Commits](https://github.com/mark3labs/mcp-go/compare/v0.39.1...v0.40.0)

---
updated-dependencies:
- dependency-name: github.com/mark3labs/mcp-go
  dependency-version: 0.40.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-22 10:28:32 +02:00
openshift-merge-bot[bot]
8f1fffe136 Merge pull request #31 from openshift/konflux/references/main
chore(deps): update konflux references main
2025-09-20 12:27:00 +00:00
red-hat-konflux[bot]
c762cdcbbc chore(deps): update konflux references main
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
2025-09-20 12:12:06 +00:00
Marc Nuri
5b33e1a065 chore(doc): fix cursor link (#334)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-18 17:11:44 +02:00
Marc Nuri
8af889bc8f test(mcp): refactor helm toolset tests (#333)
Refactor tests to new approach before adding more functionality.

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-18 16:08:53 +02:00
dependabot[bot]
76e22321f5 build(deps): bump helm.sh/helm/v3 from 3.18.6 to 3.19.0 (#321)
Bumps [helm.sh/helm/v3](https://github.com/helm/helm) from 3.18.6 to 3.19.0.
- [Release notes](https://github.com/helm/helm/releases)
- [Commits](https://github.com/helm/helm/compare/v3.18.6...v3.19.0)

---
updated-dependencies:
- dependency-name: helm.sh/helm/v3
  dependency-version: 3.19.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-18 07:13:31 +02:00
Marc Nuri
6e29a2ada5 feat(pods): update metrics to comply with new API
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-18 07:07:46 +02:00
dependabot[bot]
22de31d04d build(deps): bump k8s.io/kubectl from 0.33.4 to 0.34.1
Bumps [k8s.io/kubectl](https://github.com/kubernetes/kubectl) from 0.33.4 to 0.34.1.
- [Commits](https://github.com/kubernetes/kubectl/compare/v0.33.4...v0.34.1)

---
updated-dependencies:
- dependency-name: k8s.io/kubectl
  dependency-version: 0.34.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-18 07:07:46 +02:00
dependabot[bot]
97236a7bcd build(deps): bump golang.org/x/net from 0.42.0 to 0.44.0 (#332)
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.42.0 to 0.44.0.
- [Commits](https://github.com/golang/net/compare/v0.42.0...v0.44.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-version: 0.44.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-18 06:08:51 +02:00
Marc Nuri
94baad6570 fix(cmd): disable klog in STDIO mode (#331)
Prevents protocol issues with some clients.

Kubernetes tooling uses klog to log messages.
Some of these messages end up logged in the stderr or stdout which breaks some of the clients that expect jsonrpc messages.

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 17:03:40 +02:00
Marc Nuri
e16114dfc5 test(mcp): refactor core toolset tests (namespaces) (#330)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 15:48:57 +02:00
Marc Nuri
2bf6c549fe test(mcp): remove side-effects from toolsets tests (#329)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 12:06:33 +02:00
Marc Nuri
d6936f42d3 test(mcp): refactor events toolset tests (#328)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 11:48:35 +02:00
Marc Nuri
f496c643e7 test(mcp): refactor configuration toolset tests (#327)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 11:11:50 +02:00
Marc Nuri
d9d35b9834 test(toolsets): toolset specific metadata tests (#326)
- Refactor tests to use testify (more clarity+composability for complex tests)
- Tests for default toolsets
- Tests for configured, granular toolsets

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 11:06:17 +02:00
Marc Nuri
48cf204a89 feat(toolsets): add support for multiple toolsets in configuration (#323)
Users can now enable or disable different toolsets either by providing
a command-line flag or by setting the toolsets array field in the TOML
configuration.

Downstream Kubernetes API developers can declare toolsets for their
APIs by creating a new nested package in pkg/toolsets and registering
it in pkg/mcp/modules.go

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-17 10:53:56 +02:00
dependabot[bot]
3fc4fa49bb build(deps): bump github.com/google/jsonschema-go from 0.2.2 to 0.2.3 (#324)
Bumps [github.com/google/jsonschema-go](https://github.com/google/jsonschema-go) from 0.2.2 to 0.2.3.
- [Release notes](https://github.com/google/jsonschema-go/releases)
- [Commits](https://github.com/google/jsonschema-go/compare/v0.2.2...v0.2.3)

---
updated-dependencies:
- dependency-name: github.com/google/jsonschema-go
  dependency-version: 0.2.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-15 06:19:58 +02:00
openshift-merge-bot[bot]
a68c2a849e Merge pull request #30 from openshift/konflux/references/main
chore(deps): update konflux references main
2025-09-13 12:52:44 +00:00
red-hat-konflux[bot]
e5c959bb5f chore(deps): update konflux references main
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
2025-09-13 12:12:21 +00:00
Marc Nuri
209e8434d5 feat(mcp): toolset definitions completely agnostic from underlying MCP impl (#322)
Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-12 11:56:22 +02:00
Marc Nuri
2b6c886d95 refactor(mcp): toolset Tools definition is agnostic of MCP impl (#319)
Initial PR to make the toolsets agnostic of the usd MCP implementation (migration to go-sdk).
The decoupling will also be needed to move the different toolsets to separate nested packages (toolsets).

Signed-off-by: Marc Nuri <marc@marcnuri.com>
2025-09-12 09:58:54 +02:00
dependabot[bot]
4361a9e7d8 build(deps): bump github.com/stretchr/testify from 1.10.0 to 1.11.1 (#320)
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.10.0 to 1.11.1.
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.10.0...v1.11.1)

---
updated-dependencies:
- dependency-name: github.com/stretchr/testify
  dependency-version: 1.11.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-12 06:02:41 +02:00