diff --git a/pkg/registry/client.go b/pkg/registry/client.go index 213a9dc49..679cd690d 100644 --- a/pkg/registry/client.go +++ b/pkg/registry/client.go @@ -112,6 +112,13 @@ func NewClient(options ...ClientOption) (*Client, error) { return registryauth.EmptyCredential, errors.New("unable to retrieve credentials") } + // A blank returned username and password value is a bearer token + if username == "" && password != "" { + return registryauth.Credential{ + RefreshToken: password, + }, nil + } + return registryauth.Credential{ Username: username, Password: password,