Skip to content

Commit

Permalink
Merge pull request moby#46643 from neersighted/revert_46631
Browse files Browse the repository at this point in the history
Revert "Return no basic auth creds error when needed"
  • Loading branch information
thaJeztah authored Oct 13, 2023
2 parents c2aa895 + 40fde69 commit cdb3f9f
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions daemon/containerd/resolver.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import (
"github.com/containerd/containerd/remotes/docker"
"github.com/containerd/containerd/version"
"github.com/containerd/log"
"github.com/docker/distribution/registry/client/auth"
registrytypes "github.com/docker/docker/api/types/registry"
"github.com/docker/docker/dockerversion"
"github.com/docker/docker/pkg/useragent"
Expand Down Expand Up @@ -76,15 +75,11 @@ func authorizerFromAuthConfig(authConfig registrytypes.AuthConfig) docker.Author
"host": host,
"cfgHost": cfgHost,
}).Warn("Host doesn't match")
return "", "", auth.ErrNoBasicAuthCredentials
return "", "", nil
}
if authConfig.IdentityToken != "" {
return "", authConfig.IdentityToken, nil
}

if authConfig.Username == "" && authConfig.Password == "" {
return "", "", auth.ErrNoBasicAuthCredentials
}
return authConfig.Username, authConfig.Password, nil
}))
}
Expand Down

0 comments on commit cdb3f9f

Please sign in to comment.