Commit 8f0c70ce authored by duanjinfei's avatar duanjinfei

change docker server

parent e9b545db
package operate
import (
"example.com/m/conf"
"example.com/m/log"
"github.com/docker/docker/client"
nodemanagerV1 "github.com/odysseus/odysseus-protocol/gen/proto/go/nodemanager/v1"
......@@ -27,8 +26,8 @@ func ConnValidatorGrpc(endpoint string) witnessv1.WitnessServiceClient {
}
func GetDockerClient() (*client.Client, error) {
dockerClient, err := client.NewClientWithOpts(client.WithAPIVersionNegotiation(), client.WithHost(conf.GetConfig().DockerServer))
//dockerClient, err := client.NewClientWithOpts(client.FromEnv)
//dockerClient, err := client.NewClientWithOpts(client.WithAPIVersionNegotiation(), client.WithHost(conf.GetConfig().DockerServer))
dockerClient, err := client.NewClientWithOpts(client.FromEnv)
if err != nil {
log.WithField("error", err).Error("create docker client failed")
return nil, err
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment