feat: make ADC the default option for GCP authentication when using go-containerregistry#9456
Merged
renzodavid9 merged 1 commit intoJul 2, 2024
Conversation
2a7bf6e to
b74dc0d
Compare
…o-containerregistry
b74dc0d to
38328db
Compare
ericzzzzzzz
approved these changes
Jun 28, 2024
Closed
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.
Related with:
gcloudCLI #9457Description
This is to remove the dependency with
gcloudCLI when interacting with a private Google Registry using the go-containerregistry libray. Changing the implementation of Skaffold's Keychain to first check if it can get the access token through Application Default Credentials, if not possible then it will fallback to usegcloudCLI.I tried to use the google.Keychain authenticator, but it will first check if the registry is a known Google registry, if not it will fail. This will be breaking a case where users have a custom domain pointing to a Google Registry and configured in their
.docker/config.json:Looks like that case is possible according to https://cloud.google.com/blog/topics/developers-practitioners/hack-your-own-custom-domains-container-registry
Also extending logic to detect known Google Registries (so they don't need to be configured in
.docker/config.json)Follow-up Work (remove if N/A)
We're still missing more places to remove the
gclouddependency. More coming.