summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Burkholder <pburkholder@chef.io>2015-07-16 21:38:24 -0400
committerPeter Burkholder <pburkholder@chef.io>2015-07-16 21:38:24 -0400
commit22957d7ae4ac6f470bfbc7fedf200b35c162a9b5 (patch)
tree5cb2d7b42ddda305fb72e667fb39489b11a30054
parent50019e5af50c4e2c269179543474d80d2458efc2 (diff)
downloadchef-pdb/debug_bootstrap_command_render.tar.gz
Move debug to _before_ the sudo password is addedpdb/debug_bootstrap_command_render
-rw-r--r--lib/chef/knife/bootstrap.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/knife/bootstrap.rb b/lib/chef/knife/bootstrap.rb
index 8b3e3debbc..0229b97b0b 100644
--- a/lib/chef/knife/bootstrap.rb
+++ b/lib/chef/knife/bootstrap.rb
@@ -383,13 +383,13 @@ class Chef
def ssh_command
command = render_template
+ Chef::Log.debug("Bootstrap command has rendered as: ")
+ Chef::Log.debug(command)
+
if config[:use_sudo]
command = config[:use_sudo_password] ? "echo '#{config[:ssh_password]}' | sudo -SH #{command}" : "sudo -H #{command}"
end
- Chef::Log.debug("Bootstrap command has rendered as: ")
- Chef::Log.debug(command)
-
command
end
end