Skip to content

Document authServerRef field and combined auth patterns#702

Open
tgrunnagle wants to merge 3 commits intomainfrom
issue_671_authServerRef
Open

Document authServerRef field and combined auth patterns#702
tgrunnagle wants to merge 3 commits intomainfrom
issue_671_authServerRef

Conversation

@tgrunnagle
Copy link
Copy Markdown
Contributor

Closes #671

Summary

Document the new authServerRef field on MCPServer and MCPRemoteProxy resources, which separates embedded authorization server configuration (incoming auth) from externalAuthConfigRef (outgoing auth). This enables configuring both the embedded auth server and an outgoing auth type like AWS STS on the same resource, as introduced in RFC-0050.

Changes made

Kubernetes auth guide (guides-k8s/auth-k8s.mdx)

  • Updated the embedded auth server setup (Approach 5, Step 5) to use authServerRef as the primary configuration field, with highlighted YAML showing kind and name
  • Added a backward compatibility note explaining that externalAuthConfigRef with type: embeddedAuthServer still works
  • Revised the "combining embedded auth with outgoing auth" tip to show authServerRef + externalAuthConfigRef as the primary pattern
  • Updated troubleshooting guidance to reference both authServerRef.name and externalAuthConfigRef.name

Embedded auth server concept page (concepts/embedded-auth-server.mdx)

  • Added a new "Configuring the embedded auth server with authServerRef" section explaining the field, its TypedLocalObjectReference syntax, and when to use it vs. externalAuthConfigRef
  • Updated the MCPServer vs. VirtualMCPServer comparison table to mention authServerRef and add a "Combined auth" row
  • Added a note clarifying that authServerRef is not available on VirtualMCPServer

AWS STS integration tutorial (integrations/aws-sts.mdx)

  • Added a "Combine embedded auth with AWS STS" section with a complete MCPRemoteProxy YAML example showing authServerRef and externalAuthConfigRef together
  • Included an explanation of how each field works in the combined pattern
  • Fixed quoting on CPU/memory resource values for YAML consistency

Backend auth concept page (concepts/backend-auth.mdx)

  • Added a paragraph in the AWS STS section describing the combined auth pattern and linking to the full example

Testing

  • Run npm run build to verify all pages build without errors
  • Visually inspect each updated page via npm run start
  • Verify all internal cross-links resolve correctly
  • Confirm YAML examples use correct authServerRef syntax with kind and name

Additional notes

  • No breaking changes. Existing externalAuthConfigRef with type: embeddedAuthServer continues to work and is explicitly documented as backward compatible.
  • Depends on the upstream operator changes from RFC-0050 being released before these docs go live.
  • The auto-generated CRD reference (reference/crd-spec.md) is not modified here; it will be regenerated from the toolhive repo.

tgrunnagle and others added 2 commits April 13, 2026 09:20
Implements changes for issue #671:
- Update auth-k8s.mdx to use authServerRef as primary example in Step 5
- Add backward compatibility note for externalAuthConfigRef
- Add combined embedded auth + AWS STS section in aws-sts.mdx
- Add authServerRef configuration section in embedded-auth-server.mdx
- Update MCPServer vs VirtualMCPServer table with authServerRef info
- Add combined auth pattern reference in backend-auth.mdx
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel bot commented Apr 13, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs-website Ready Ready Preview, Comment Apr 13, 2026 4:42pm

Request Review

@tgrunnagle tgrunnagle marked this pull request as ready for review April 13, 2026 16:40
Comment on lines 391 to +397
resources:
limits:
cpu: '500m'
memory: 512Mi
memory: '512Mi'
requests:
cpu: 100m
memory: 128Mi
cpu: '100m'
memory: '128Mi'
Copy link
Copy Markdown
Collaborator

@danbarr danbarr Apr 13, 2026

Choose a reason for hiding this comment

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

Are the resource settings actually relevant to the topic/example? Consider removing if not - or validate that these are in fact the right recommended resources for MCPRemoteProxy; I think these are the same as carried forward from other full MCPServer examples.

Comment on lines +466 to +476

audit:
enabled: true

resources:
limits:
cpu: '500m'
memory: '512Mi'
requests:
cpu: '100m'
memory: '128Mi'
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Are the audit and resource settings actually relevant to the example? Consider removing if not.

Copy link
Copy Markdown
Collaborator

@danbarr danbarr left a comment

Choose a reason for hiding this comment

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

The content and accuracy of the new authServerRef documentation looks good, but the placement of the new "Combine embedded auth with AWS STS" section in aws-sts.mdx needs fixing before this merges.

The section is inserted between Step 4 and Step 5 of the numbered tutorial. A reader following the main path hits an advanced/optional topic mid-flow before completing the tutorial. It should sit after all the main tutorial steps are complete - either after Step 5 or at the end of the page before "Next steps" - as an optional advanced section.

Low-priority: the new authServerRef section in concepts/embedded-auth-server.mdx states "This is the preferred configuration method" in the opening sentence and then restates "The authServerRef field is the preferred way to configure the embedded auth server" two paragraphs later. One instance can be dropped.

embedded authorization server, and `oidcConfig` validates the JWTs that the
embedded authorization server issues. Unlike approaches 1-3 where `oidcConfig`
points to an external identity provider, here it points to the embedded
authorization server itself—the `oidcConfig` issuer must match the `issuer` in
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Remove em dash

Suggested change
authorization server itself—the `oidcConfig` issuer must match the `issuer` in
authorization server itself. The `oidcConfig` issuer must match the `issuer` in

[Set up embedded authorization server authentication](../guides-k8s/auth-k8s.mdx#set-up-embedded-authorization-server-authentication)
(steps 1 through 4). Then deploy the `MCPRemoteProxy` with both references:

```yaml {10-12,14-15} title="aws-mcp-remote-proxy-combined.yaml"
Copy link
Copy Markdown
Collaborator

@danbarr danbarr Apr 13, 2026

Choose a reason for hiding this comment

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

Highlight is misaligned. Tip: using the # highlight-start and # highlight-end comments is usually easier than using the numbered indicators (especially for LLMs that can't count).

Suggested change
```yaml {10-12,14-15} title="aws-mcp-remote-proxy-combined.yaml"
```yaml {10-12,15-16} title="aws-mcp-remote-proxy-combined.yaml"

but `authServerRef` is preferred for consistency. When you need both incoming
and outgoing auth on the same resource, you must use `authServerRef` for the
embedded auth server so that `externalAuthConfigRef` remains available for the
outgoing auth configuration.
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.

should we document the old way if we want to make it obsolete more or less?

configuration separate from outgoing auth types like AWS STS or token exchange.
If you need both incoming and outgoing auth on the same resource, you must use
`authServerRef` for the embedded auth server so that `externalAuthConfigRef`
remains available for the outgoing auth configuration.
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.

same comment about only documenting our preferred way of configuring the authserver

embedded auth server. This separates the two configurations so they don't
compete for the same field:
Use `authServerRef` for the embedded auth server and `externalAuthConfigRef` for
outgoing auth (such as AWS STS) on the same resource. This is the primary use
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.

I know the reason you did all the work was AWS STS, but should we make it more explicit that any outgoing auth can be configured using the same mechanism?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update docs-website for authServerRef and combined auth patterns

3 participants