Skip to content

feat(agentregistry): add GKE manifests and JSON spec samples - #15004

Open
fatoboist wants to merge 1 commit into
mainfrom
feat/agentregistry-gke-and-specs
Open

fatoboist wants to merge 1 commit into
mainfrom
feat/agentregistry-gke-and-specs

Conversation

@fatoboist

Copy link
Copy Markdown
Contributor

Description

Adds the Agent Registry GKE deployment manifests and JSON specification samples under agentregistry/gke/ and agentregistry/specs/ (PR C of migrating inline Agent Registry documentation snippets to GitHub; internal tracking: b/581932768).

Files added

  • agentregistry/gke/agent-deployment.yaml (agentregistry_gke_agent_manifest)
  • agentregistry/gke/mcp-server-deployment.yaml (agentregistry_gke_mcp_server_manifest)
  • agentregistry/specs/agent-card.json (whole-file include, no region tags)
  • agentregistry/specs/toolspec.json (whole-file include, no region tags)

Checklist

Testing

  • I have tested this change on a live environment and verified it works as intended. (Static GKE manifest and JSON spec samples; validated JSON/YAML syntax.)

Compliance & Style


Post-Approval Actions

  • Please merge this PR for me once it is approved

@fatoboist
fatoboist requested review from a team as code owners November 27, 2026 17:37
@product-auto-label product-auto-label Bot added the api: agentregistry Issues related to the Agent Registry API. label Nov 27, 2026
@snippet-bot

snippet-bot Bot commented Nov 27, 2026

Copy link
Copy Markdown

Here is the summary of changes.

You are about to add 2 region tags.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@product-auto-label product-auto-label Bot added the samples Issues that are directly related to samples. label Nov 27, 2026

@gemini-code-assist gemini-code-assist 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.

Code Review

This pull request introduces GKE deployment manifests for an agent and an MCP server, along with JSON specifications for an agent card and tools. Feedback on the MCP server deployment highlights two issues: the URL annotation uses HTTPS which complicates deployment by requiring TLS configuration, and the manifest lacks a Kubernetes Service and container port definitions, preventing in-cluster traffic routing.

Comment on lines +24 to +31
# Endpoint URLs where the GKE controller can access this MCP server
modelcontextprotocol.info/urls: |
- https://my-mcp-server.default.svc.cluster.local/mcp
# Defines structural capabilities for the MCP server card
modelcontextprotocol.info/capabilities: |
card:
endpoint: "/mcp"
protocol: "HTTP"

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.

medium

The URL in modelcontextprotocol.info/urls uses https://, which typically requires configuring TLS certificates inside the container. For a basic GKE sample, using http:// is more standard and simplifies deployment. Consider changing the scheme to http.

    # Endpoint URLs where the GKE controller can access this MCP server
    modelcontextprotocol.info/urls: |
      - http://my-mcp-server.default.svc.cluster.local/mcp
    # Defines structural capabilities for the MCP server card
    modelcontextprotocol.info/capabilities: |
      card:
        endpoint: "/mcp"
        protocol: "HTTP"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Not applying this change: this manifest is extracted from the published Agent Registry GKE documentation (register-mcp-servers.md), which uses https://my-mcp-server.default.svc.cluster.local/mcp alongside iam.gke.io/spiffe-identity-type: agent-identity. Keeping https:// preserves parity with the documented example.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

+1 from the TW side — keeping exact parity with register-mcp-servers.md makes sense for this migration PR.

Comment on lines +43 to +47
spec:
containers:
- name: server
image: gcr.io/PROJECT_ID/my-mcp-server:1.0.0
# [END agentregistry_gke_mcp_server_manifest]

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.

medium

The deployment defines an in-cluster URL my-mcp-server.default.svc.cluster.local but does not define a corresponding Kubernetes Service or expose any container ports. Without a Service, the GKE controller and other in-cluster clients will not be able to route traffic to the MCP server pod. Consider exposing port 8080 on the container and adding a Service named my-mcp-server to route traffic.

    spec:
      containers:
      - name: server
        image: gcr.io/PROJECT_ID/my-mcp-server:1.0.0
        ports:
        - containerPort: 8080
---
# Kubernetes Service for in-cluster network routing to the MCP server pod
apiVersion: v1
kind: Service
metadata:
  name: my-mcp-server
  labels:
    app: my-mcp-server
spec:
  type: ClusterIP
  ports:
  - port: 80
    targetPort: 8080
    protocol: TCP
    name: http
  selector:
    app: my-mcp-server
# [END agentregistry_gke_mcp_server_manifest]

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Not applying this change: this sample intentionally mirrors the focused GKE deployment manifest for an MCP server snippet in register-mcp-servers.md, which illustrates only the Deployment labels and modelcontextprotocol.info/* / iam.gke.io/* annotations required for Agent Registry registration (unlike agent-deployment.yaml, which explicitly includes a Service). Keeping it scoped to the Deployment avoids diverging from the doc walkthrough.

@evelyn-goo evelyn-goo left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

One blocking TW item: agentregistry/specs/toolspec.json is missing the _meta / com.googleapis.iap/PolicyHints block that register-mcp-servers.md explains right below the snippet. Once that's added back, this looks good to go

Comment on lines +13 to +21
"name": "create_support_ticket",
"description": "Creates a new support ticket in the issue tracking system.",
"annotations": {
"title": "Create Support Ticket",
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": true
}
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

issue (blocking): This is missing the _meta / com.googleapis.iap/PolicyHints block on create_support_ticket that's currently in register-mcp-servers.md:

      "_meta": {
        "com.googleapis.iap/PolicyHints": {
          "authorization": {
            "toolDisabled": false,
            "hitlMode": "HITL_MODE_ALWAYS"
          }
        }
      }

The two paragraphs immediately below the snippet in register-mcp-servers.md explicitly walk through _meta, com.googleapis.iap/PolicyHints, toolDisabled, and hitlMode, so we need to keep that block in toolspec.json to preserve parity with the doc.

spec:
containers:
- name: server
image: gcr.io/PROJECT_ID/my-agent:1.0.0

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

nit (non-blocking): Both GKE manifests match our current docs accurately! Just flagging for a future follow-up (not blocking this migration): gcr.io/PROJECT_ID/... uses legacy Container Registry, so we should consider migrating both the docs and these manifests to Artifact Registry (REGION-docker.pkg.dev/...) in a separate pass.

Comment on lines +24 to +31
# Endpoint URLs where the GKE controller can access this MCP server
modelcontextprotocol.info/urls: |
- https://my-mcp-server.default.svc.cluster.local/mcp
# Defines structural capabilities for the MCP server card
modelcontextprotocol.info/capabilities: |
card:
endpoint: "/mcp"
protocol: "HTTP"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

+1 from the TW side — keeping exact parity with register-mcp-servers.md makes sense for this migration PR.

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

Labels

api: agentregistry Issues related to the Agent Registry API. samples Issues that are directly related to samples.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants