Hi!
I have multiple projects and try to use ansible for all of them.
One of idea was to make my playbooks more flexible by specified variable files for each project. In this case i have one role - deploy software and multiple playbooks with config like this
<script src="https://gist.github.com/anonymous/35117b7088079fba8af4.js"></script>
But when i try to use some variables from dbvars file for hosts in db group - ansible say that cant find this variable. If i specified in this host group project_name - all work fine... It make me little confused, because i specified this variable for all hosts on top...
Try to insert nice code from playbook and fail :)
Here is current link
Thanks for your reply!
I have multiple projects and each of them have webservers, bases or other groups. With your solution i need to use various names for this groups - test_app, prod1_app, prod2_app and others.. It will be real hard to manage all this group names
My point is - why variable from "all" section in playbook doesnt work in lower part of same playbook - for app or db hosts. And how to deal with it :)
R.