Merge pull request #12009 from duglin/AddConfig

Migrate .dockercfg to .docker/config.json and support for HTTP Headers
This commit is contained in:
Alexander Morozov
2015-04-20 13:12:17 -07:00
19 changed files with 360 additions and 81 deletions
+2 -2
View File
@@ -437,13 +437,13 @@ func (b *Builder) pullImage(name string) (*imagepkg.Image, error) {
}
pullRegistryAuth := b.AuthConfig
if len(b.AuthConfigFile.Configs) > 0 {
if len(b.ConfigFile.AuthConfigs) > 0 {
// The request came with a full auth config file, we prefer to use that
repoInfo, err := b.Daemon.RegistryService.ResolveRepository(remote)
if err != nil {
return nil, err
}
resolvedAuth := b.AuthConfigFile.ResolveAuthConfig(repoInfo.Index)
resolvedAuth := b.ConfigFile.ResolveAuthConfig(repoInfo.Index)
pullRegistryAuth = &resolvedAuth
}