Worth a read probably: https://jpetazzo.github.io/2015/09/03/do-not-use-docker-in-docker-for-ci/ from a Docker team member.
For your case, might be even simpler to also bind mount the docker client binary in your container. That way you can keep your Dockerfile independent of that. Also, beware that using bind mounts for data is generally not recommended. Better use a named volume (since data volume containers are somehow now deprecated). Cheers Just wanted to share some of my experiences with building Docker containers using a dockerized Jenkins setup. For people like me who are running simple Jenkins setup on their home hardware this might be interesting to read: https://renzedevries.wordpress.com/2016/06/30/building-containers-with-docker-in-docker-and-jenkins/ Look forward to hearing some feedback on this and if other people are having similar setups. There is not a lot of information on this subject, but I do see a huge potential for a mobile Jenkins docker solution, where you can run your CI anywhere, specially given the new Jenkins pipelines this becomes very interesting, just deploy the Jenkins container and go. -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/ff8b6639-ff66-46e2-8617-a3d6d02a9511%40googlegroups.com <https://groups.google.com/d/msgid/jenkinsci-users/ff8b6639-ff66-46e2-8617-a3d6d02a9511%40googlegroups.com?utm_medium=email&utm_source=footer> . For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CANWgJS7XYJ4%3DgaVkt3FFV1LLMqckKtXRg0NX1XuHL%3D8Uc1hMrA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.