Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ansible runs N number of times (where N=vms.size) #140

Open
br0ziliy opened this issue Mar 16, 2016 · 2 comments
Open

Ansible runs N number of times (where N=vms.size) #140

br0ziliy opened this issue Mar 16, 2016 · 2 comments

Comments

@br0ziliy
Copy link
Collaborator

Hi James,

Ansible provisioner in Vagrant is designed to run once per each host by default.
We did worked this around by having ansible.limit='all' in 9607d41
This introduced another issue: provisioner will run that number of times, how much vms are defined in :vms: [] array in omv.yml.
Quick and dirty patch us attached (just to demonstrate the idea), but it introduces another issue: with this it's impossible to define multiple playbooks per host in the omv.yml (one global in :playbook: [] array, and one "per-vm" playbook in :vms: array.

Now I don't really see the use case of having multiple playbooks per host (as you do in examples/ansible.yml - if you agree I will submit a merge request with this patch.
If you disagree - please share your thoughts with me so I can think of another solution.
ansible_provisioner_number.txt

Thanks.
vk

@purpleidea
Copy link
Owner

hey @br0ziliy, to be honest, i don't have any strong opinions about this because i'm not really using the ansible functionality at the moment. I think if you had a more concrete example of what problem is difficult to solve with the current code, it might help me understand better.

Having said all that, since I'm focusing my attention on https://github.com/purpleidea/mgmt most of the time, I'm happy for you to have the final call for ansible design/patches.

@purpleidea
Copy link
Owner

@br0ziliy I've given you push access to the repo. I think here are the basic rules (for now):

  • No merge commits please, rebase any patches (or contributor patches) before merging.
  • Two ACK's for a commit. You're one ACK, I'm the other for now.

I'll try not to push too many "drive-by's" without telling you.
Welcome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants