Hi,
I am wondering if “ansible-pull” also provides the orchestration like what ansible does in push model.
For example I have a site.yml that dictates all DB nodes have to be provisioned first, then web nodes can be provisioned. If I run ansible from the central machine, this order can be guaranteed.
But for ansible-pull, does such kind of mechanism exist?
Thanks,
Xicheng
you can setup your web playbooks to check if the db hosts have been
provisioned first and fail if they have not.
Thanks for the reply, I think that definitely works. But if I have to write the check-db-nodes code in web playbooks, I am not using the orchestration mechanism provided by ansible. This would probably make ansible no different from chef or puppet.
In pull mode, no, if you want something different you would need a
system that supports callback, like tower (http://ansible.com/tower).
Thanks Brian. Looks like push would be a better answer if orchestration is needed. I am trying to integrate ansible with cobbler without 2nd touch(trigger ansible-playbook on the central machine when os installation completes). I also would like to use the orchestration mechanism provided by ansible. What I have in mind right now is to write a playbook that holds ansible from running on host until its port 22 is up, which means cobbler has done its job on this particular host. if, in this case, a web host(from my original question) gets installed first and the port 22 is up, will ansible ignore it until all db hosts get installed?
There are several ways to do it, I think the easiest is to run a
playbook with at least 2 plays, the first against the db hosts, the
second against the web hosts, since the 2nd won't start until the
first one is done, you should have what you want.