func checkConnection(env *config.Environment) error { err := exec.Command("docker", "info").Run() if err != nil { if runtime.GOOS == "darwin" { machine := env.GetMachine() if !machine.IsCreated() { return errors.New("Docker machine is not created. Run setup to create the machine.") } if !machine.IsBooted() { return errors.New("Docker machine is created but not booted. Run setup to boot the machine.") } } return errors.New("Unable to connect to docker daemon. " + helpConnectingToDaemon(env)) } return err }