synced_folders/rsync: add UserKnownHostsFile to /dev/null [GH-3511]

This commit is contained in:
Mitchell Hashimoto 2014-04-21 20:39:48 -07:00
parent 7cbef9b3d9
commit a47b85c8c4
2 changed files with 4 additions and 1 deletions

View File

@ -53,6 +53,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]
PLUGIN AUTHOR CHANGES:

View File

@ -57,7 +57,9 @@ module VagrantPlugins
username = ssh_info[:username]
host = ssh_info[:host]
rsh = [
"ssh -p #{ssh_info[:port]} -o StrictHostKeyChecking=no",
"ssh -p #{ssh_info[:port]} " +
"-o StrictHostKeyChecking=no " +
"-o UserKnownHostsFile=/dev/null",
ssh_info[:private_key_path].map { |p| "-i '#{p}'" },
].flatten.join(" ")