Skip to main content

Docker-in-Docker (DinD)

What is DinD?​

For a simple terms, I will use docker to run another docker in docker ðŸĪŠ

DinD

DinD Methodology

Why is it?​

It can be used in many cases, but I use it to simulate a multi-host environment on a single physical machine.

How to do it?​

Open your command line and run it

docker run --privileged -d --name <your-docker-name> docker:dind 

That's it, now I have a "virtual" of virtual machine to deploy and run the image

Warning ❗❗❗: Because it run with --privileged, so it's only use for dev/test environment => Never use in production