From 54c71b9331ed69c8f504ba2d51f03b7ec7a4fbf9 Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Thu, 28 Apr 2016 20:27:18 +0200 Subject: [PATCH] Add a better solution for the ssh_known_hosts issue Fix https://github.com/ansible/ansible/issues/10172 too --- lib/ansible/modules/source_control/git.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/ansible/modules/source_control/git.py b/lib/ansible/modules/source_control/git.py index ea310254a7..04ef7dda7f 100644 --- a/lib/ansible/modules/source_control/git.py +++ b/lib/ansible/modules/source_control/git.py @@ -179,7 +179,8 @@ requirements: notes: - "If the task seems to be hanging, first verify remote host is in C(known_hosts). SSH will prompt user to authorize the first contact with a remote host. To avoid this prompt, - one solution is to add the remote host public key in C(/etc/ssh/ssh_known_hosts) before calling + one solution is to use the option accept_hostkey. Another solution is to + add the remote host public key in C(/etc/ssh/ssh_known_hosts) before calling the git module, with the following command: ssh-keyscan -H remote_host.com >> /etc/ssh/ssh_known_hosts." '''