I planned to use docker-compose and a few scripts to manage the deployment of my app on staging and production.
My idea was to use one docker-compose.yml
with one .env
file for each environment. In those .env
files I would have set some specific values and the version of the different images that compose my application.
But then I discovered Ansible and it looks like my few scripts powered by a community of experts. So I started to investigate it and I would like to use it.
Based on the best practices, I can easily imagine having a standard directory layout[1] with the one inventory for each environment. And a couple of roles.
However, I have no idea how to manage the versions; how to describe which version is executed in one environment?
Ideally, I would like to find a simple solution where my CI can update this version.
Thanks
[1] https://docs.ansible.com/ansible/latest/user_guide/playbooks_best_practices.html#directory-layout