mirror of https://github.com/docker/docs.git
Merge pull request #7745 from LK4D4/fix_docker_host_panic
Fix panic for DOCKER_HOST without ://
This commit is contained in:
commit
b458dd1dfb
|
@ -44,7 +44,8 @@ func main() {
|
||||||
// If we do not have a host, default to unix socket
|
// If we do not have a host, default to unix socket
|
||||||
defaultHost = fmt.Sprintf("unix://%s", api.DEFAULTUNIXSOCKET)
|
defaultHost = fmt.Sprintf("unix://%s", api.DEFAULTUNIXSOCKET)
|
||||||
}
|
}
|
||||||
if _, err := api.ValidateHost(defaultHost); err != nil {
|
defaultHost, err := api.ValidateHost(defaultHost)
|
||||||
|
if err != nil {
|
||||||
log.Fatal(err)
|
log.Fatal(err)
|
||||||
}
|
}
|
||||||
flHosts = append(flHosts, defaultHost)
|
flHosts = append(flHosts, defaultHost)
|
||||||
|
|
Loading…
Reference in New Issue