How to develop your ansible code easily with docker ?
If you use ansible, maybe you want to test your code as much as possible. Usually, I use some virtual machines to do that. Sometimes i use vagrant with virtualbox or other times KVM. But using is not the more efficient solution to test your code. Because, virtual servers take some times to be up and ready and with ansible it’s useful to drop and recreate servers.

To change that, I decide to use containers. This solution is very lighter and a container can be up in few seconds or less. I created a dockerfile which provides for the installation of ssh and systemd into a debian container. And when you want you can quickly and easily recreate many containers.
You can find the code in this repositories.
And if you want to see an explaination you can see this video where I explain it.