From 53830123fd52d0ef6da4cb904493e1ff1e8cc0be Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Wed, 3 Sep 2014 21:04:14 +0200 Subject: [PATCH] Make ssh debug easier to read and paste Currently, ansible -vvvv show the following: hostname EXEC ['ssh', '-C', '-vvv', '-o', 'ControlMaster=auto', This is not good if someone want to cut and paste it to see if something is wrong with the command line, so join the dictionnary strings with spaces to have 1 string in the output. --- lib/ansible/runner/connection_plugins/ssh.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/runner/connection_plugins/ssh.py b/lib/ansible/runner/connection_plugins/ssh.py index f63f0af020..fdf5f0dc6e 100644 --- a/lib/ansible/runner/connection_plugins/ssh.py +++ b/lib/ansible/runner/connection_plugins/ssh.py @@ -286,7 +286,7 @@ class Connection(object): sudocmd, prompt, success_key = utils.make_sudo_cmd(sudo_user, executable, cmd) ssh_cmd.append(sudocmd) - vvv("EXEC %s" % ssh_cmd, host=self.host) + vvv("EXEC %s" % ' '.join(ssh_cmd), host=self.host) not_in_host_file = self.not_in_host_file(self.host)