In Docker Toolbox for the Mac, there is a reasonable way to run Docker itself inside a Docker container. The use case is a CI workflow that produces Docker artifacts. There’s a pretty good discussion here: http://jpetazzo.github.io/2015/09/03/do-not-use-docker-in-docker-for-ci/
In Docker on real Linux, it’s very easy, with just these volume mounts from the host to the CI container:
docker run ... \ -v $(which docker):/usr/bin/docker \ -v /var/run/docker.sock:/var/run/docker.sock \
My question is, how to do the same with Docker for Mac? I’ve tried all variations I can think of of the Linux technique above. I can share the .sock between the host and the CI container, but not the Docker executable itself.