From 091d9e047971cee42193cc3c5fa30bc552175bcf Mon Sep 17 00:00:00 2001 From: sawanoboly Date: Thu, 24 Sep 2015 19:49:02 +0900 Subject: pass ssh_password to session --- lib/chef/knife/ssh.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/chef/knife') diff --git a/lib/chef/knife/ssh.rb b/lib/chef/knife/ssh.rb index 62af853e88..d2df8399db 100644 --- a/lib/chef/knife/ssh.rb +++ b/lib/chef/knife/ssh.rb @@ -225,6 +225,8 @@ class Chef if config[:identity_file] opts[:keys] = File.expand_path(config[:identity_file]) opts[:keys_only] = true + elsif config[:ssh_password] + opts[:password] = config[:ssh_password] end # Don't set the keys to nil if we don't have them. forward_agent = config[:forward_agent] || ssh_config[:forward_agent] -- cgit v1.2.1