ailispaw / boot2docker-xhyve

Boot2Docker running on xhyve hypervisor
294 stars 25 forks source link

`docker` cli tools don't work from mac to boot2docker #8

Closed awinder closed 9 years ago

awinder commented 9 years ago

Having a weird issue on a clean install on a new mac (I've been running this for the past month and it's been a breeze!) If I make ssh, I'm able to get into the boot2docker instance just fine, and docker commands work without an issue. When I try from my mac though, I get an instant reply:

Cannot connect to the Docker daemon. Is 'docker -d' running on this host?

I'm setting DOCKER_HOST with the results of make ip (in the standard format, like tcp://192.168.64.2:2375). Any idea what could be going wrong or anything I can provide to help debug this?

ailispaw commented 9 years ago

Have you modified my scripts and/or re-created boot2docker-data.img?

Could you make sure the value of DOCKER_HOST again?

Could you check the process of docker daemon in the VM with ps ax | grep docker? I would like to see parameters of that.

ailispaw commented 9 years ago

How about the other environment variables for docker cli? DOCKER_TLS_VERIFY and/or DOCKER_CERT_PATH

if they have something, try the following.

unset DOCKER_TLS_VERIFY
unset DOCKER_CERT_PATH
export DOCKER_HOST=tcp://`make ip`:2375
awinder commented 9 years ago

Aha! That was it, I created my own boot2docker-data.img (for a larger disk) and it somehow had a corrupted partition table. Recreating that and then relaunching the VM cleared things up. Thanks!

ailispaw commented 9 years ago

You're welcome. That's good to know. Thanks for opening an issue.

awinder commented 9 years ago

Sure thing, thank YOU for the great project :smile: