The Idea is pretty simple, Can we use a docker container to buid the pipelines inside it, without talking to the docker outside of the container. following this It is possible to use podman instead of docker. And this specifies that it is possible to emulate the docker socket in podman Use Docker Compose with Podman to Orchestrate Containers on Fedora Linux - Fedora Magazine.
There are no plans to formally support Podman instead of Docker, however, please keep in mind that Drone Runners are conceptually similar to Kubernetes Operators in that anyone can create a Drone runner. See this thread:
Hello, I discover that podman has a socket for docker compatibility and that I have successfuly started a runner with podman instead of docker.
I got interested in this build because my drone runner wasn’t building docker images and buildah also wasn’t working, now I have both working fine
Here is the how to:
you will need podman and podman-docker, in fedora and centos there are 2 different packages for each one but in ubuntu there is only podman. After installing it you will be able to verify that you have the podman server running if you can run systemctl status podman.socket
. You must take notes of where the socket is running which can be seen in the status command
As you can see, my was running in the /run/podman/podman.sock
With that out of the way, you can run the container with:
sudo podman run -d \
-e DRONE_RPC_PROTO="https" \
-e DRONE_RPC_HOST="YOURDOMAIN" \
-e DRONE_RPC_SECRET="YOUR_SECRET" \
-e DRONE_RUNNER_CAPACITY=2 \
-e DRONE_RUNNER_NAME="NAME" \
--restart always \
--name runner \
-v [YOUR_SOCKET_PATH]:/var/run/docker.sock \
docker.io/drone/drone-runner-docker
Finally I recommend checking the /etc/containers/registries.conf
to see if you got any registries configuration there, if you don’t I recommend:
unqualified-search-registries = ["docker.io"]