ansible_local provisioner tuning example
According to @gildegoma in #9863, here's a concrete example about tuning ansible(_local) provisioner.
This commit is contained in:
parent
dbba41a7ec
commit
4b896d9945
|
@ -80,6 +80,20 @@ Some of these options are for advanced usage only and should not be used unless
|
|||
|
||||
`ansible-galaxy install --role-file=%{role_file} --roles-path=%{roles_path} --force`
|
||||
|
||||
Example:
|
||||
|
||||
```ruby
|
||||
Vagrant.configure(2) do |config|
|
||||
config.vm.box = "centos/7"
|
||||
config.vm.provision "ansible_local" do |ansible|
|
||||
ansible.playbook = "/vagrant/playbook.yml"
|
||||
ansible.galaxy_role_file = "/vagrant/requirements.yml"
|
||||
ansible.galaxy_role_path = "/etc/ansible/roles"
|
||||
ansible.galaxy_command = "ansible-galaxy install --force --ignore-certs --role-file=%{role_file} --roles-path=%{roles_path}"
|
||||
end
|
||||
end
|
||||
```
|
||||
|
||||
- `galaxy_role_file` (string) - The path to the Ansible Galaxy role file.
|
||||
|
||||
By default, this option is set to `nil` and Galaxy support is then disabled.
|
||||
|
|
Loading…
Reference in New Issue