feat(mcp): authorize GCP backend endpoint - #44
Open
xnoto wants to merge 2 commits into
Open
Conversation
Contributor
OpenTofu TestOpenTofu test passed. View run output |
This was referenced Sep 9, 2026
Contributor
OpenTofu PlanOpenTofu plan passed. View run outputOpenTofu will perform the following actions:
# cloudflare_zero_trust_access_application.mcp_gateway_backend["makeitwork-gcp"] will be created
+ resource "cloudflare_zero_trust_access_application" "mcp_gateway_backend" {
+ account_id = (sensitive value)
+ allowed_idps = [
+ "e584ea47-1251-4939-95f4-4daf4a58cd31",
]
+ app_launcher_visible = true
+ aud = (known after apply)
+ destinations = (known after apply)
+ domain = "mcp-makeitwork-gcp.makeitwork.cloud"
+ http_only_cookie_attribute = true
+ id = (known after apply)
+ name = "MCP makeitwork-gcp"
+ policies = [
+ {
+ decision = "non_identity"
+ include = [
+ {
[REDACTED: potentially sensitive plan output]
[REDACTED: potentially sensitive plan output]
}
},
]
+ name = "mcp-gateway-clients"
+ precedence = 1
},
+ {
+ decision = "allow"
+ include = [
+ {
+ group = {
+ id = "e0d9e873-31d7-4536-9234-3dad8a99d84d"
}
},
]
+ name = "makeitworkcloud-admins"
+ precedence = 2
},
]
+ self_hosted_domains = (known after apply)
+ session_duration = "24h"
+ type = "self_hosted"
}
Plan: 1 to add, 0 to change, 0 to destroy.
OpenTofu will perform the following actions:
# cloudflare_zero_trust_access_application.mcp_gateway_backend["makeitwork-gcp"] will be created
+ resource "cloudflare_zero_trust_access_application" "mcp_gateway_backend" {
+ account_id = (sensitive value)
+ allowed_idps = [
+ "e584ea47-1251-4939-95f4-4daf4a58cd31",
]
+ app_launcher_visible = true
+ aud = (known after apply)
+ destinations = (known after apply)
+ domain = "mcp-makeitwork-gcp.makeitwork.cloud"
+ http_only_cookie_attribute = true
+ id = (known after apply)
+ name = "MCP makeitwork-gcp"
+ policies = [
+ {
+ decision = "non_identity"
+ include = [
+ {
[REDACTED: potentially sensitive plan output]
[REDACTED: potentially sensitive plan output]
}
},
]
+ name = "mcp-gateway-clients"
+ precedence = 1
},
+ {
+ decision = "allow"
+ include = [
+ {
+ group = {
+ id = "e0d9e873-31d7-4536-9234-3dad8a99d84d"
}
},
]
+ name = "makeitworkcloud-admins"
+ precedence = 2
},
]
+ self_hosted_domains = (known after apply)
+ session_duration = "24h"
+ type = "self_hosted"
}
Plan: 1 to add, 0 to change, 0 to destroy. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Repository has no pull-request template.
Summary
Adds
makeitwork-gcpto the per-backend MCP Access application set incf-access-mcp.tf, creating the fail-closed Access application formcp-makeitwork-gcp.makeitwork.cloudunder the existing MCP Gateway service-token and GitHub-admin policies.No new service token, tunnel identity, DNS record, workload route, provider version, workflow, or secret is created here.
kustomize-clusterowns the later TunnelBinding route and must not merge it until this PR has merged and its environment-gated apply has completed.Fixes # N/A — owner-directed direct GCP MCP endpoint.
Type of change
Validation
testandplan) succeeded.for_eachresource is already documented inREADME.md, and adding one list key does not change the generated resource inventory. CIterraform docspassed unchanged.Plan: 1 to add, 0 to change, 0 to destroy:cloudflare_zero_trust_access_application.mcp_gateway_backend["makeitwork-gcp"]for domainmcp-makeitwork-gcp.makeitwork.cloud.Pre-PR review evidence:
ADVANCE; no Critical/High findings; required the PR plan to show only the intended Access application (confirmed above).ADVANCE; two Low notes — the shared non-expiring service token's reach expands by design to this additional read-only backend, and route ordering is an operational dependency.ADVANCE; ordering, rollback, and consumer-PR correction gates recorded.Impact and rollout
Producer:
tfroot-cloudflareis the canonical Cloudflare Access owner. Consumer: the existing ToolHivemakeitwork-gcpbackend and a laterkustomize-clusterTunnelBinding route.Ordered delivery:
PR CI validates and plans this Access-only change.(passed)main; approve the environment-gated production apply.mcp-makeitwork-gcp.makeitwork.cloudexists.kustomize-clusterroute PR (branchfeat/mcp-gcp-direct-endpoint, whose README carries an explicit do-not-merge gate).codex-config#5,claude-config#5,opencode-config#17) add directmakeitwork-gcpentries; merge only after the route is live.Rollback: remove the TunnelBinding route first, then revert this list addition through a new reviewed PR and environment-gated apply.
Safety and secrets
AI-assisted change: an OpenCode agent materially produced this change. Reviewers should verify the list key, expected plan delta, and that no workload DNS ownership moves into this root.