Add log_only to debug messages (#25545)

Fixes #25544
When `debug` is enabled the debug messages triggered
from `bin/ansible-connection` should be logged only to file
and not on stdout.
This commit is contained in:
Ganesh Nalawade
2017-06-13 18:41:33 +05:30
committed by GitHub
parent 343a709800
commit 9e8cc26720
3 changed files with 7 additions and 6 deletions

View File

@@ -290,7 +290,7 @@ def main():
sys.stderr.write(traceback.format_exc())
sys.exit("FAIL: %s" % e)
ssh = connection_loader.get('ssh', class_only=True)
ssh = connection_loader.get('ssh', class_only=True, log_only=True)
cp = ssh._create_control_path(pc.remote_addr, pc.connection, pc.remote_user)
# create the persistent connection dir if need be and create the paths