Skip to content

Add support for GCS auth in both resolution and jar download phases#1611

Open
acecilia wants to merge 1 commit into
bazel-contrib:masterfrom
acecilia:8-gcs-support
Open

Add support for GCS auth in both resolution and jar download phases#1611
acecilia wants to merge 1 commit into
bazel-contrib:masterfrom
acecilia:8-gcs-support

Conversation

@acecilia

Copy link
Copy Markdown

Add support for GCS auth in both resolution and jar download phases:

  • Resolution phase:

    • Gradle resolver:
      • The resolver now converts gcs:// to https://storage.googleapis.com/
      • Auth token is obtained using the google-auth-library-oauth2-http library. GcpTokenProvider wraps the calls to the library
    • Maven resolver:
      • GcsDownloadService SPI plugin uses google-cloud-storage library, and delegates non-GCS URIs to the default service. HttpDownloaderTransporterFactory now accepts gcs scheme
      • Auth token is obtained by the google-cloud-storage library
  • Jar download phase:

    • download_pinned_deps.bzl converts gcs:// to https:// inline and uses Bazel's http_file
    • Auth token is obtained via Bazel --credential_helper (delegated to the client to configure). Example of credential helper here

@acecilia
acecilia requested review from cheister, jin and shs96c as code owners July 21, 2026 23:32
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.

1 participant