-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for the Authenticated Registries #744
Add support for the Authenticated Registries #744
Conversation
236a069
to
cf269d4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works beautifully!
I particularly like the fact that we don't default to authenticated access which would uselessly slow down the production central repo access. Using the environment variable allows to only affect repos that really need authentication.
To use registries that require authentication to host Tanzu CLI Plugins images users are expected to do the following: 1. Use `docker login <registry>` or `crane auth login <registry>` to authenticate with the registry 2. Specify environment variable `TANZU_CLI_AUTHENTICATED_REGISTRY=<registry>`. By specifying this environment variable, Tanzu CLI will use the default authentication mechanism instead of using Anonymous access to fetch images.
cf269d4
to
84ed515
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @anujc25
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks!
To use registries that require authentication to host Tanzu CLI Plugins images users are expected to do the following: 1. Use `docker login <registry>` or `crane auth login <registry>` to authenticate with the registry 2. Specify environment variable `TANZU_CLI_AUTHENTICATED_REGISTRY=<registry>`. By specifying this environment variable, Tanzu CLI will use the default authentication mechanism instead of using Anonymous access to fetch images.
To use registries that require authentication to host Tanzu CLI Plugins images users are expected to do the following: 1. Use `docker login <registry>` or `crane auth login <registry>` to authenticate with the registry 2. Specify environment variable `TANZU_CLI_AUTHENTICATED_REGISTRY=<registry>`. By specifying this environment variable, Tanzu CLI will use the default authentication mechanism instead of using Anonymous access to fetch images.
What this PR does / why we need it
docker login <registry>
orcrane auth login <registry>
to authenticate with the registryTANZU_CLI_AUTHENTICATED_REGISTRY=<registry>
. By specifying this environment variable, Tanzu CLI will use the default authentication mechanism instead of usingAnonymous
access to fetch images.Pending
Which issue(s) this PR fixes
Fixes #
Describe testing done for PR
localhost:6002
as discovery sourcedocker login
orcrane auth login
) and try againRelease note
Additional information
Special notes for your reviewer