Skip to content

[FEATURE] Kubernetes workspaces give their pods MCP servers #1760

Description

@edenreich

Summary

A Kubernetes workspace's pod never sees this machine's mcp.yaml. Its pod daemon only has the servers baked into its image or rendered by the operator, so an agent on its own computer cannot reach a hosted server such as AgentMail.

inference-gateway/operator#321 lets an Orchestrator carry named servers with a URL and headers, and renders them into the pod's mcp.yaml. #1756 (PR #1758) already gives the pod its credentials through the workspace's secrets. What is missing is the workspace saying which servers its pods get.

Proposed shape: a Kubernetes workspace names servers from this daemon's mcp.yaml, and the adapter writes them into each new Orchestrator.

# ~/.infer/mcp.yaml
servers:
  - name: agentmail
    enabled: true
    url: https://mcp.agentmail.to/mcp
    headers:
      x-api-key: ${AGENTMAIL_API_KEY}

# ~/.infer/daemon.yaml
workspaces:
  - name: code-reviewer
    kind: kubernetes
    namespace: agents
    secrets:
      - code-reviewer-credentials
    mcp_servers:
      - agentmail

The CLI expands ${VAR} when it loads mcp.yaml. Forwarding a server as loaded would put this machine's value of AGENTMAIL_API_KEY, or an empty one, into the Orchestrator. The adapter has to forward the header as written, so ${AGENTMAIL_API_KEY} stays a reference that the pod expands from the variable its Secret provides.

Acceptance Criteria

  • A Kubernetes workspace accepts mcp_servers, naming servers of this daemon's mcp.yaml. Setting it on any other kind fails validation, like secrets.
  • When a session's Orchestrator is created, each named server goes into its spec.mcp with its name, URL and headers, and MCP is enabled for it.
  • Header values are forwarded exactly as written in mcp.yaml, never expanded on this machine. A header whose value is not a ${VAR} reference is refused with an error naming the server, so no secret ever lands in a Kubernetes object.
  • A container server (run: true), or a name mcp.yaml does not have, fails the teleport before anything is created, with an error naming the server.
  • An operator that predates operator#321 fails the create with the existing "upgrade the operator" error, naming the version it needs.
  • Servers are read when the Orchestrator is created, like secrets, so running sessions keep theirs.
  • docs/daemon.md documents mcp_servers beside secrets, with the AgentMail example.

Related: inference-gateway/desktop#476, where a server can be given to an agent's own Kubernetes computer. An agent's own mcpServers picks among the servers its computer has.

Activity

  1. added
    enhancement
    on Nov 8, 2026
  2. added theissue type on Nov 8, 2026
  3. moved this from Todo to In progress in 2026on Nov 8, 2026
  4. moved this from In progress to QA in 2026on Nov 8, 2026
  5. moved this from QA to Done in 2026on Nov 8, 2026
  6. inference-gateway-releaser commented on Nov 9, 2026

    @inference-gateway-releaser
    Contributor

    🎉 This issue has been resolved in version 0.250.0 🎉

    The release is available on:

    Your semantic-release bot 📦🚀

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementreleased

    Projects

    • Status
      Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions