mirror of https://github.com/docker/cli.git
specify specific permissions
When creating manifest lists, don't use "*" as the permission when creating the token handler. This causes problems with gitlab's repos. Fixes https://github.com/docker/cli/issues/1010 Signed-off-by: Christy Norman <christy@linux.vnet.ibm.com>
This commit is contained in:
parent
4970824bea
commit
c26e2264fb
|
@ -102,7 +102,7 @@ func getHTTPTransport(authConfig authtypes.AuthConfig, endpoint registry.APIEndp
|
|||
modifiers = append(modifiers, auth.NewAuthorizer(challengeManager, passThruTokenHandler))
|
||||
} else {
|
||||
creds := registry.NewStaticCredentialStore(&authConfig)
|
||||
tokenHandler := auth.NewTokenHandler(authTransport, creds, repoName, "*")
|
||||
tokenHandler := auth.NewTokenHandler(authTransport, creds, repoName, "push", "pull")
|
||||
basicHandler := auth.NewBasicHandler(creds)
|
||||
modifiers = append(modifiers, auth.NewAuthorizer(challengeManager, tokenHandler, basicHandler))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue