provisioners/ansible: use the first private key
/cc @gildegoma - Does Ansible support multiple private keys? Vagrant now does, so this isn't exactly safe.
This commit is contained in:
parent
c5018c5e01
commit
cd106986b4
|
@ -4,8 +4,11 @@ module VagrantPlugins
|
|||
def provision
|
||||
ssh = @machine.ssh_info
|
||||
|
||||
# Connect with Vagrant user (unless --user or --private-key are overidden by 'raw_arguments')
|
||||
options = %W[--private-key=#{ssh[:private_key_path]} --user=#{ssh[:username]}]
|
||||
# Connect with Vagrant user (unless --user or --private-key are
|
||||
# overidden by 'raw_arguments').
|
||||
#
|
||||
# TODO: multiple private key support
|
||||
options = %W[--private-key=#{ssh[:private_key_path][0]} --user=#{ssh[:username]}]
|
||||
|
||||
# Joker! Not (yet) supported arguments can be passed this way.
|
||||
options << "#{config.raw_arguments}" if config.raw_arguments
|
||||
|
|
Loading…
Reference in New Issue