From b56994d11d5290aeebde033fcf260482954635ca Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Sat, 5 Jun 2010 18:52:12 -0700 Subject: [PATCH] Internal SSH ignores ssh config file. Also added `PasswordAuthentication no` to ssh-config output --- lib/vagrant/ssh.rb | 5 ++++- templates/ssh_config.erb | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/vagrant/ssh.rb b/lib/vagrant/ssh.rb index 3a5f24487..a0397785d 100644 --- a/lib/vagrant/ssh.rb +++ b/lib/vagrant/ssh.rb @@ -48,7 +48,10 @@ module Vagrant Net::SSH.start(env.config.ssh.host, env.config[:ssh][:username], opts.merge( :port => port, - :keys => [env.config.ssh.private_key_path])) do |ssh| + :keys => [env.config.ssh.private_key_path], + :user_known_hosts_file => [], + :paranoid => false, + :config => false)) do |ssh| yield SSH::Session.new(ssh) end end diff --git a/templates/ssh_config.erb b/templates/ssh_config.erb index f5131f467..e7f98d9c8 100644 --- a/templates/ssh_config.erb +++ b/templates/ssh_config.erb @@ -4,4 +4,5 @@ Host <%= host_key %> Port <%= ssh_port %> UserKnownHostsFile /dev/null StrictHostKeyChecking no + PasswordAuthentication no IdentityFile <%= private_key_path %>