There is no way to actually run a
docker daemon in a container, but we can pass docker cli and docker daemon through volume mirroring.
Let’s run a container along with those we need mirrored.
docker run -it \
-v /usr/bin/docker:/usr/bin/docker \
-v /var/run/docker.sock:/var/run/docker.sock \
Inside this container we can actually call the
The reason for me to do this is that I want to call docker cli in a gitlab-runner/docker executor during pipeline. The executor itself is a docker container.
Thus, I configured the runner this way:
image = "ubuntu"
volumes = [