mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
Merge pull request #372 from tsl0922/patch-1
Set private key for proxy_command
This commit is contained in:
commit
4b7fedbd42
@ -48,8 +48,8 @@ module VagrantPlugins
|
|||||||
:forward_agent => machine.config.ssh.forward_agent,
|
:forward_agent => machine.config.ssh.forward_agent,
|
||||||
:forward_x11 => machine.config.ssh.forward_x11,
|
:forward_x11 => machine.config.ssh.forward_x11,
|
||||||
}
|
}
|
||||||
|
|
||||||
ssh_info[:proxy_command] = "ssh '#{machine.provider_config.host}' -l '#{machine.provider_config.username}' nc %h %p" if machine.provider_config.connect_via_ssh
|
ssh_info[:proxy_command] = "ssh '#{machine.provider_config.host}' -l '#{machine.provider_config.username}' -i '#{machine.provider_config.id_ssh_key_file}' nc %h %p" if machine.provider_config.connect_via_ssh
|
||||||
|
|
||||||
ssh_info
|
ssh_info
|
||||||
end
|
end
|
||||||
|
@ -248,7 +248,7 @@ module VagrantPlugins
|
|||||||
# set ssh key for access to libvirt host
|
# set ssh key for access to libvirt host
|
||||||
uri << "\&keyfile="
|
uri << "\&keyfile="
|
||||||
# if no slash, prepend $HOME/.ssh/
|
# if no slash, prepend $HOME/.ssh/
|
||||||
uri << "#{`echo ${HOME}`.chomp}/.ssh/" if @id_ssh_key_file !~ /\A\//
|
@id_ssh_key_file.prepend("#{`echo ${HOME}`.chomp}/.ssh/") if @id_ssh_key_file !~ /\A\//
|
||||||
uri << @id_ssh_key_file
|
uri << @id_ssh_key_file
|
||||||
end
|
end
|
||||||
# set path to libvirt socket
|
# set path to libvirt socket
|
||||||
|
Loading…
Reference in New Issue
Block a user