From 16c6cbae4f155c6f8c626fc69cca41ebee1a9e05 Mon Sep 17 00:00:00 2001 From: elijah Date: Fri, 7 Mar 2014 01:20:24 -0800 Subject: added IdentitiesOnly ssh option to both ssh command and ruby Net::SSH options -- this should prevent ssh from trying all the keys in ~/.ssh. you might still get the error "Too many authentication failures" if you have a ton of keys activated in ~/.ssh/config --- lib/leap_cli/util/remote_command.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/leap_cli/util/remote_command.rb') diff --git a/lib/leap_cli/util/remote_command.rb b/lib/leap_cli/util/remote_command.rb index c24a543..93d1bd1 100644 --- a/lib/leap_cli/util/remote_command.rb +++ b/lib/leap_cli/util/remote_command.rb @@ -99,6 +99,7 @@ module LeapCli; module Util; module RemoteCommand opts = {} if node.vagrant? opts[:keys] = [vagrant_ssh_key_file] + opts[:keys_only] = true # only use the keys specified above, and ignore whatever keys the ssh-agent is aware of. opts[:paranoid] = false # we skip host checking for vagrant nodes, because fingerprint is different for everyone. if LeapCli::log_level <= 1 opts[:verbose] = :error # suppress all the warnings about adding host keys to known_hosts, since it is not actually doing that. -- cgit v1.2.3