Closed tknerr closed 9 years ago
Anyhow you can get quite far with this today already, e.g.:
Vagrant.configure("2") do |config|
provisioner = Vagrant::Util::Platform.windows? ? :ansible : :ansible_guest
config.vm.provision provisioner do |ansible|
ansible.playbook = "any_playbook.yml"
end
end
Btw: my assumption is that the config options are in sync with the original :ansible
provisioner, are they?
Frankly you caught me off-guard with this one, let me check what can I do...
PR's are always welcome, BTW!
@vovimayhem thanks for taking you time to look at it! I just wanted to capture the idea and put it on for discussion. I'm not sure whether there is so much added value in it, given the workaround mentioned above. Mostly wanted to hear your opinion on it... :-)
As for the PRs - yes, definitely. For now I only skimmed the README and it looks promising. I will give it a try next week. Once I'm on it, and I see need for things being improved, I might be in for PRs as well :-)
Considering the typical use case that you are using this plugin to make vagrant / ansible provisioning available to windows users, it would be nice if there were less repetition in the Vagrantfile.
Eg. instead of:
Rather something like that:
Does this make sense?
I'm not sure because there might be some config options (e.g. paths) which are specific to either host or guest...