Docker Community Forums

Share and learn in the Docker community.

Command works on "docker for windows" but not on "boot2docker"


(Vinayagg) #1

I am trying to run docker from within a docker.

it does run from within “docker for windows”. However, now we need to use dockers on windows 7 and I configured boot2docker and this command does not run properly.

Can anyone help?

Commands
docker run --rm -i -t --privileged=true -v /var/run/docker.sock:/var/run/docker.sock -v /usr/lib64/libdevmapper.so.1.02:/usr/lib/libdevmapper.so.1.02 -v /usr/bin/docker:/bin/docker alpine docker images

Output:
docker: Error response from daemon: Container command ‘docker’ not found or does not exist…


(Gavinjonespf) #2

IMHO I’d use bins in the container itself, rather than trying to bind volumes.
e.g. something like:

Note this is using Ubuntu, but you could easily sub out for alpine.

then:
sudo docker run --rm -it --name docker-toolbox -v /var/run/docker.sock:/var/run/docker.sock:ro gavinjonespf/docker-toolbox:latest bash