mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
Provider does not need to set username
If the user sets this themselves, vagrant will pick it up. If the user does not set it, vagrant will set a default. All this works without any code on our end.
This commit is contained in:
@@ -43,17 +43,12 @@ module VagrantPlugins
|
||||
ssh_info = {
|
||||
:host => ip_address,
|
||||
:port => machine.config.ssh.guest_port,
|
||||
:username => machine.config.ssh.username,
|
||||
:forward_agent => machine.config.ssh.forward_agent,
|
||||
: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
|
||||
|
||||
if not ssh_info[:username]
|
||||
ssh_info[:username] = machine.config.ssh.default.username
|
||||
end
|
||||
|
||||
ssh_info
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user