diff --git a/CHANGELOG.md b/CHANGELOG.md index 8d0459056..4406a431f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,6 +61,7 @@ BUG FIXES: - synced\_folders/nfs: Acquires a process-level lock so exports don't collide with Vagrant running in parallel. - synced\_folders/rsync: Add UserKnownHostsFile option to not complain. [GH-3511] + - synced\_folders/rsync: Proxy command is used properly if set. [GH-3553] PLUGIN AUTHOR CHANGES: diff --git a/plugins/synced_folders/rsync/helper.rb b/plugins/synced_folders/rsync/helper.rb index ae47f8b97..aa21cddfa 100644 --- a/plugins/synced_folders/rsync/helper.rb +++ b/plugins/synced_folders/rsync/helper.rb @@ -56,7 +56,11 @@ module VagrantPlugins # Connection information username = ssh_info[:username] host = ssh_info[:host] - proxy_command = "-o ProxyCommand='#{ssh_info[:proxy_command]}' " if ssh_info[:proxy_command] + proxy_command = "" + if ssh_info[:proxy_command] + proxy_command = "-o ProxyCommand='#{ssh_info[:proxy_command]}' " + end + rsh = [ "ssh -p #{ssh_info[:port]} " + proxy_command +