3 ms·
I love Ansible, and we migrated our Rails deployment from Chef to Ansible. Now we have a subfolder /ops in our project that contains all the code to provision o
by pqdbr 6y ago
I love Ansible, and we migrated our Rails deployment from Chef to Ansible. Now we have a subfolder /ops in our project that contains all the code to provision our infrastructure and deploy our app.
However, I still find it very hard to manage updating roles. Git submodules is just terrible, and you can't have a different git repo for each role subfolder. So how do you manage updating third-party roles?
- webknjaz 6y agoWith Ansible Collections, it'll be easier because it's a proper packaging format. The tarball are uploaded to Galaxy, it's not just pointing to GitHub. OTOH talking about Git: I usually recommend using subtrees in place of submodules as they allow you to actually merge-in the contents of other trees rather than holding pointers to them.
- geerlingguy 6y agoRoles in collections are still a bit more annoying to deal with (IMO) than roles on their own (which I typically store in individual git repos so I can mix-and-match them in my playbooks more easily, and can test each role in CI thoroughly).
- TavsiE9s 6y agoIf you can't migrate to collections or you've got local roles that are in VCS take a look at ansible-galaxy's requirements.yml file (see https://galaxy.ansible.com/docs/using/installing.html#installing-multiple-roles-from-a-file https://galaxy.ansible.com/docs/using/installing.html#instal...).