Skip to content

Commit f89e5b1

Browse files
renovate[bot]github-actions[bot]Radoslav Dimitrov
authored
Update stacklok/toolhive to v0.23.1 (#759)
* Update stacklok/toolhive to v0.23.1 Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Refresh reference assets for toolhive v0.23.1 * Add upstream-release-docs content for v0.23.1 Source-verified against stacklok/toolhive@v0.23.1. - Bump apiVersion from v1alpha1 to v1beta1 across 40 guide, integration, and tutorial MDX files. migrate-to-v1beta1.mdx is excluded so historical "before" examples stay accurate. - Add v0.23.0 section to migrate-to-v1beta1.mdx covering the CRD API graduation, zero-downtime upgrade behavior, and manifest migration steps. - Add "Default callback URL for upstream providers" subsection to auth-k8s.mdx documenting the {resourceUrl}/oauth/callback default applied when redirectUri is omitted. * Docs-review fixes on v0.23.1 release docs - migrate-to-v1beta1.mdx: replace the kubectl --raw API discovery command with a jq query over CRD status.storedVersions, which actually identifies CRDs still holding v1alpha1-stored resources (the previous command only listed kinds served at v1alpha1, always all of them). - auth-k8s.mdx: smooth out the awkward leading-ellipsis sentence in the "Default callback URL for upstream providers" section by merging it into the preceding sentence and dropping the parenthetical em-dash-like aside in favor of a natural "for example" clause. Co-authored-by: Radoslav Dimitrov <undefined@users.noreply.github.com> * Apply prettier and eslint fixups to skill output --------- Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com> Co-authored-by: Radoslav Dimitrov <undefined@users.noreply.github.com>
1 parent c79729e commit f89e5b1

80 files changed

Lines changed: 368 additions & 248 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/upstream-projects.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ projects:
3535

3636
- id: toolhive
3737
repo: stacklok/toolhive
38-
version: v0.22.0
38+
version: v0.23.1
3939
docs_paths:
4040
- docs/toolhive/guides-cli
4141
- docs/toolhive/guides-k8s

docs/toolhive/guides-cli/build-containers.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ thv build --tag mcp-servers/git-server:stable uvx://mcp-server-git
101101
Use the built image in your Kubernetes manifests:
102102

103103
```yaml
104-
apiVersion: toolhive.stacklok.dev/v1alpha1
104+
apiVersion: toolhive.stacklok.dev/v1beta1
105105
kind: MCPServer
106106
metadata:
107107
name: git-server
@@ -263,7 +263,7 @@ you need to pre-build containers before deploying them.
263263
3. **Deploy to Kubernetes** using the pre-built image:
264264

265265
```yaml
266-
apiVersion: toolhive.stacklok.dev/v1alpha1
266+
apiVersion: toolhive.stacklok.dev/v1beta1
267267
kind: MCPServer
268268
metadata:
269269
name: git-server

docs/toolhive/guides-k8s/auth-k8s.mdx

Lines changed: 58 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ isolation.
107107
<TabItem value="inline" label="External IdP" default>
108108

109109
```yaml title="shared-oidc-config.yaml"
110-
apiVersion: toolhive.stacklok.dev/v1alpha1
110+
apiVersion: toolhive.stacklok.dev/v1beta1
111111
kind: MCPOIDCConfig
112112
metadata:
113113
name: production-oidc
@@ -127,7 +127,7 @@ spec:
127127
<TabItem value="k8s" label="Kubernetes service account">
128128
129129
```yaml title="k8s-oidc-config.yaml"
130-
apiVersion: toolhive.stacklok.dev/v1alpha1
130+
apiVersion: toolhive.stacklok.dev/v1beta1
131131
kind: MCPOIDCConfig
132132
metadata:
133133
name: k8s-sa-oidc
@@ -154,7 +154,7 @@ Use `oidcConfigRef` instead of inline `oidcConfig`. Each server must set a
154154
unique `audience` to prevent token replay across servers:
155155

156156
```yaml title="mcp-server-shared-oidc.yaml"
157-
apiVersion: toolhive.stacklok.dev/v1alpha1
157+
apiVersion: toolhive.stacklok.dev/v1beta1
158158
kind: MCPServer
159159
metadata:
160160
name: weather-server
@@ -217,7 +217,7 @@ settings, and an `MCPServer` resource that references it. The ToolHive proxy
217217
handles authentication before forwarding requests to the MCP server.
218218

219219
```yaml title="mcp-server-external-auth.yaml"
220-
apiVersion: toolhive.stacklok.dev/v1alpha1
220+
apiVersion: toolhive.stacklok.dev/v1beta1
221221
kind: MCPOIDCConfig
222222
metadata:
223223
name: external-oidc
@@ -229,7 +229,7 @@ spec:
229229
clientId: 'your-client-id'
230230
jwksUrl: 'https://your-oidc-issuer.com/path/to/jwks'
231231
---
232-
apiVersion: toolhive.stacklok.dev/v1alpha1
232+
apiVersion: toolhive.stacklok.dev/v1beta1
233233
kind: MCPServer
234234
metadata:
235235
name: weather-server-external
@@ -310,7 +310,7 @@ Create an `MCPOIDCConfig` resource for Kubernetes service account authentication
310310
and an `MCPServer` that references it:
311311

312312
```yaml title="mcp-server-k8s-auth.yaml"
313-
apiVersion: toolhive.stacklok.dev/v1alpha1
313+
apiVersion: toolhive.stacklok.dev/v1beta1
314314
kind: MCPOIDCConfig
315315
metadata:
316316
name: k8s-sa-oidc
@@ -321,7 +321,7 @@ spec:
321321
serviceAccount: 'mcp-client'
322322
namespace: 'client-apps'
323323
---
324-
apiVersion: toolhive.stacklok.dev/v1alpha1
324+
apiVersion: toolhive.stacklok.dev/v1beta1
325325
kind: MCPServer
326326
metadata:
327327
name: weather-server-k8s
@@ -499,7 +499,7 @@ Create an `MCPExternalAuthConfig` resource with the `embeddedAuthServer` type.
499499
This example configures an OIDC upstream provider (the most common case):
500500

501501
```yaml title="embedded-auth-config.yaml"
502-
apiVersion: toolhive.stacklok.dev/v1alpha1
502+
apiVersion: toolhive.stacklok.dev/v1beta1
503503
kind: MCPExternalAuthConfig
504504
metadata:
505505
name: embedded-auth-server
@@ -562,7 +562,7 @@ authorization server itself. The MCPOIDCConfig issuer must match the `issuer` in
562562
your `MCPExternalAuthConfig`.
563563

564564
```yaml title="mcp-server-embedded-auth.yaml"
565-
apiVersion: toolhive.stacklok.dev/v1alpha1
565+
apiVersion: toolhive.stacklok.dev/v1beta1
566566
kind: MCPOIDCConfig
567567
metadata:
568568
name: embedded-auth-oidc
@@ -573,7 +573,7 @@ spec:
573573
# This must match the embedded authorization server issuer url
574574
issuer: 'https://mcp.example.com'
575575
---
576-
apiVersion: toolhive.stacklok.dev/v1alpha1
576+
apiVersion: toolhive.stacklok.dev/v1beta1
577577
kind: MCPServer
578578
metadata:
579579
name: weather-server-embedded
@@ -690,7 +690,7 @@ for providers like GitHub that use OAuth 2.0 but don't implement the full OIDC
690690
specification.
691691

692692
```yaml title="embedded-auth-oauth2-config.yaml"
693-
apiVersion: toolhive.stacklok.dev/v1alpha1
693+
apiVersion: toolhive.stacklok.dev/v1beta1
694694
kind: MCPExternalAuthConfig
695695
metadata:
696696
name: embedded-auth-oauth2
@@ -788,6 +788,51 @@ refresh-token state), add `prompt: 'consent'` alongside `access_type: 'offline'`
788788
- Google then shows the consent screen on every login and re-issues a refresh
789789
token each time.
790790

791+
### Default callback URL for upstream providers
792+
793+
When you omit `redirectUri` from an upstream provider's `oidcConfig` or
794+
`oauth2Config`, the operator defaults it to `{resourceUrl}/oauth/callback`.
795+
`resourceUrl` is the `oidcConfigRef.resourceUrl` set on the MCPServer or
796+
VirtualMCPServer that references this MCPExternalAuthConfig. It's typically the
797+
external URL that MCP clients use to reach the server.
798+
799+
You still need to register this callback URL with your upstream OAuth2 or OIDC
800+
provider before the flow can complete. Use the same URL on both sides: the value
801+
computed from `resourceUrl` here, and the authorized redirect URI in your
802+
provider's application settings.
803+
804+
For example, given this `oidcConfigRef` on an MCPServer:
805+
806+
```yaml
807+
spec:
808+
oidcConfigRef:
809+
name: embedded-auth-oidc
810+
audience: 'https://mcp.example.com/mcp'
811+
resourceUrl: 'https://mcp.example.com/mcp'
812+
```
813+
814+
Omitting `redirectUri` on the upstream provider resolves the callback to
815+
`https://mcp.example.com/mcp/oauth/callback`:
816+
817+
```yaml
818+
upstreamProviders:
819+
- name: google
820+
type: oidc
821+
oidcConfig:
822+
issuerUrl: 'https://accounts.google.com'
823+
clientId: '<YOUR_GOOGLE_CLIENT_ID>'
824+
clientSecretRef:
825+
name: upstream-idp-secret
826+
key: client-secret
827+
# redirectUri omitted - defaults to:
828+
# https://mcp.example.com/mcp/oauth/callback
829+
```
830+
831+
Set `redirectUri` explicitly if you need a non-default callback path, for
832+
example to route the callback through a separate gateway hostname. If
833+
`resourceUrl` is also unset, no default is applied and the upstream provider
834+
must have `redirectUri` set explicitly.
835+
791836
## Set up authorization
792837

793838
All authentication approaches can use the same authorization configuration using
@@ -836,7 +881,7 @@ kubectl apply -f authz-configmap.yaml
836881
Add the authorization configuration to your `MCPServer` resources:
837882

838883
```yaml title="mcp-server-with-authz.yaml"
839-
apiVersion: toolhive.stacklok.dev/v1alpha1
884+
apiVersion: toolhive.stacklok.dev/v1beta1
840885
kind: MCPOIDCConfig
841886
metadata:
842887
name: k8s-sa-authz-oidc
@@ -847,7 +892,7 @@ spec:
847892
serviceAccount: 'mcp-client'
848893
namespace: 'client-apps'
849894
---
850-
apiVersion: toolhive.stacklok.dev/v1alpha1
895+
apiVersion: toolhive.stacklok.dev/v1beta1
851896
kind: MCPServer
852897
metadata:
853898
name: weather-server-with-authz

docs/toolhive/guides-k8s/connect-clients.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ First, ensure you have an MCP server deployed. This example uses the `fetch`
105105
server:
106106

107107
```yaml title="fetch-server.yaml"
108-
apiVersion: toolhive.stacklok.dev/v1alpha1
108+
apiVersion: toolhive.stacklok.dev/v1beta1
109109
kind: MCPServer
110110
metadata:
111111
name: fetch
@@ -235,7 +235,7 @@ First, in the MCPServer spec for each server, ensure the `resourceUrl` property
235235
is set to the full client-facing URL via `oidcConfigRef`:
236236

237237
```yaml title="fetch-server-oauth.yaml"
238-
apiVersion: toolhive.stacklok.dev/v1alpha1
238+
apiVersion: toolhive.stacklok.dev/v1beta1
239239
kind: MCPServer
240240
# ...
241241
spec:
@@ -493,7 +493,7 @@ First, in the MCPServer spec for each server, ensure the `resourceUrl` property
493493
is set to the full client-facing URL via `oidcConfigRef`:
494494

495495
```yaml title="fetch-server-oauth.yaml"
496-
apiVersion: toolhive.stacklok.dev/v1alpha1
496+
apiVersion: toolhive.stacklok.dev/v1beta1
497497
kind: MCPServer
498498
# ...
499499
spec:

docs/toolhive/guides-k8s/customize-tools.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ descriptions. You reference the configuration from an MCPServer using the
2323
This example exposes only three tools on a server:
2424

2525
```yaml title="toolconfig-basic.yaml"
26-
apiVersion: toolhive.stacklok.dev/v1alpha1
26+
apiVersion: toolhive.stacklok.dev/v1beta1
2727
kind: MCPToolConfig
2828
metadata:
2929
name: basic-tool-filter
@@ -51,7 +51,7 @@ scopes (for example, separate GitHub orgs, repos, or environments). Renaming
5151
tools makes intent obvious and helps prevent mistakes.
5252

5353
```yaml title="toolconfig-with-overrides.yaml"
54-
apiVersion: toolhive.stacklok.dev/v1alpha1
54+
apiVersion: toolhive.stacklok.dev/v1beta1
5555
kind: MCPToolConfig
5656
metadata:
5757
name: github-tools-config
@@ -112,7 +112,7 @@ resource.
112112
<TabItem value="mcpserver" label="MCPServer" default>
113113

114114
```yaml {10-11} title="mcpserver-with-toolconfig.yaml"
115-
apiVersion: toolhive.stacklok.dev/v1alpha1
115+
apiVersion: toolhive.stacklok.dev/v1beta1
116116
kind: MCPServer
117117
metadata:
118118
name: github
@@ -130,7 +130,7 @@ spec:
130130
<TabItem value="mcpremoteproxy" label="MCPRemoteProxy">
131131

132132
```yaml {10-11} title="mcpremoteproxy-with-toolconfig.yaml"
133-
apiVersion: toolhive.stacklok.dev/v1alpha1
133+
apiVersion: toolhive.stacklok.dev/v1beta1
134134
kind: MCPRemoteProxy
135135
metadata:
136136
name: github
@@ -161,7 +161,7 @@ Run the GitHub MCP twice, once per organization, and rename tools so intent is
161161
clear to clients.
162162

163163
```yaml title="github-org-scoped-tools.yaml"
164-
apiVersion: toolhive.stacklok.dev/v1alpha1
164+
apiVersion: toolhive.stacklok.dev/v1beta1
165165
kind: MCPToolConfig
166166
metadata:
167167
name: github-acme-tools
@@ -176,7 +176,7 @@ spec:
176176
get_pull_request:
177177
name: github_acme_get_pr
178178
---
179-
apiVersion: toolhive.stacklok.dev/v1alpha1
179+
apiVersion: toolhive.stacklok.dev/v1beta1
180180
kind: MCPToolConfig
181181
metadata:
182182
name: github-foocorp-tools
@@ -191,7 +191,7 @@ spec:
191191
get_pull_request:
192192
name: github_foocorp_get_pr
193193
---
194-
apiVersion: toolhive.stacklok.dev/v1alpha1
194+
apiVersion: toolhive.stacklok.dev/v1beta1
195195
kind: MCPServer
196196
metadata:
197197
name: github-acme
@@ -204,7 +204,7 @@ spec:
204204
toolConfigRef:
205205
name: github-acme-tools
206206
---
207-
apiVersion: toolhive.stacklok.dev/v1alpha1
207+
apiVersion: toolhive.stacklok.dev/v1beta1
208208
kind: MCPServer
209209
metadata:
210210
name: github-foocorp

docs/toolhive/guides-k8s/logging.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ your MCP server manifest:
8484
<TabItem value="mcpserver" label="MCPServer" default>
8585

8686
```yaml {11-12}
87-
apiVersion: toolhive.stacklok.dev/v1alpha1
87+
apiVersion: toolhive.stacklok.dev/v1beta1
8888
kind: MCPServer
8989
metadata:
9090
name: <SERVER_NAME>
@@ -102,7 +102,7 @@ spec:
102102
<TabItem value="mcpremoteproxy" label="MCPRemoteProxy">
103103
104104
```yaml {11-12}
105-
apiVersion: toolhive.stacklok.dev/v1alpha1
105+
apiVersion: toolhive.stacklok.dev/v1beta1
106106
kind: MCPRemoteProxy
107107
metadata:
108108
name: <SERVER_NAME>
@@ -120,7 +120,7 @@ spec:
120120
<TabItem value="virtualmcpserver" label="VirtualMCPServer">
121121
122122
```yaml {11-14}
123-
apiVersion: toolhive.stacklok.dev/v1alpha1
123+
apiVersion: toolhive.stacklok.dev/v1beta1
124124
kind: VirtualMCPServer
125125
metadata:
126126
name: <SERVER_NAME>

0 commit comments

Comments
 (0)