docs: document Google Cloud service-account auth (API + registry)#25
Merged
Conversation
Add a subsection on authenticating to registry.deploys.app with a Google Cloud service account: log in with `oauth2accesstoken` + a short-lived access token, which must carry the userinfo.email scope (the registry resolves the caller's identity from the token's email), and grant the SA email a role with registry.push/registry.pull on the project. Includes a GitHub Actions snippet. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Preview deleted (PR closed). |
The API accepts a Google Cloud SA access token as the bearer token (not just the registry). Document it in the API overview's Authentication section: the token needs the userinfo.email scope and the SA email must be granted the required permissions; cross-link the registry section. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Document authenticating to deploys.app with a Google Cloud service account — no deploys.app key needed — across the three auth surfaces:
content/api/overview.md) — pass a Google Cloud SA access token asAuthorization: Bearer.content/registry/overview.md) —docker login registry.deploys.app -u oauth2accesstoken -p <access-token>.content/automation/cli.md) — put a SA access token inDEPLOYS_TOKEN(with agcloud auth print-access-token --scopes=…userinfo.emailexample).All three note the two requirements:
userinfo.emailscope — deploys.app identifies the caller by the token's email; acloud-platform-only token is rejected asunauthorized.<name>@<project>.iam.gserviceaccount.com) must be granted the needed permissions /registry.push/registry.pullvia Roles.The CLI and registry sections cross-link the API section as the canonical reference.
Why
This is the non-obvious auth path we used to push the CLI image from CI (deploys#21) — it applies to the whole API, the registry, and the CLI, so all three are now documented.
Verified:
/access/roles/+/access/service-accounts/pages exist;registry.push/registry.pullare the real permission strings; the CLI'sDEPLOYS_TOKENis sent as a Bearer token (so a Google access token works), while its ADC fallback mints tokens without an explicit scope — hence the docs steer the SA path throughDEPLOYS_TOKEN.🤖 Generated with Claude Code