Merge pull request #8576 from afbjorklund/image-client

cache: Only use docker client for docker runtime
pull/8698/head
Sharif Elgamal 2020-07-15 11:12:52 -07:00 committed by GitHub
commit 1467e8f7c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -83,10 +83,12 @@ func LoadImages(cc *config.ClusterConfig, runner command.Runner, images []string
return errors.Wrap(err, "runtime")
}
imgClient, err := client.NewClientWithOpts(client.FromEnv) // image client
if err != nil {
glog.Infof("couldn't get a local image daemon which might be ok: %v", err)
imgClient = nil
var imgClient *client.Client
if cr.Name() == "Docker" {
imgClient, err = client.NewClientWithOpts(client.FromEnv) // image client
if err != nil {
glog.Infof("couldn't get a local image daemon which might be ok: %v", err)
}
}
for _, image := range images {