From c2b43787c58b6049ba11e37cf73c03528cce4122 Mon Sep 17 00:00:00 2001 From: Collin Allen Date: Fri, 5 Apr 2013 08:43:45 -0700 Subject: [PATCH] Make Ansible extra_vars a hash instead of a string --- plugins/provisioners/ansible/provisioner.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/provisioners/ansible/provisioner.rb b/plugins/provisioners/ansible/provisioner.rb index e4284fe6e..8891f0357 100644 --- a/plugins/provisioners/ansible/provisioner.rb +++ b/plugins/provisioners/ansible/provisioner.rb @@ -5,7 +5,7 @@ module VagrantPlugins ssh = @machine.ssh_info options = %W[--private-key=#{ssh[:private_key_path]} --user=#{ssh[:username]}] - options << "--extra-vars=\"#{config.extra_vars}\"" if config.extra_vars + options << "--extra-vars=" + config.extra_vars.map{|k,v| "#{k}=#{v}"}.join(' ') if config.extra_vars options << "--inventory-file=#{config.inventory_file}" if config.inventory_file options << "--ask-sudo-pass" if config.ask_sudo_pass