]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
internal.vm_setup: call ssh with -o StrictHostKeyChecking=no 403/head
authorDan Mick <dan.mick@redhat.com>
Tue, 13 Jan 2015 23:15:09 +0000 (15:15 -0800)
committerDan Mick <dan.mick@redhat.com>
Tue, 13 Jan 2015 23:16:23 +0000 (15:16 -0800)
If one doesn't have this configured for ssh, the call to
ssh for vps'es in vm_setup will cause a tty prompt to accept
the unknown key.

Fixes: #10530
Signed-off-by: Dan Mick <dan.mick@redhat.com>
teuthology/task/internal.py

index 6a6a0803cc1d3755f52166f327299510fd0f0f75..2f50902f97851d7b1ad14f1f173d05ce06b9df6d 100644 (file)
@@ -609,7 +609,17 @@ def vm_setup(ctx, config):
                         check_status=False,)
                 if r.returncode != 0:
                     p1 = subprocess.Popen(['cat', editinfo], stdout=subprocess.PIPE)
-                    p2 = subprocess.Popen(['ssh', '-t', '-t', str(rem), 'sudo', 'sh'], stdin=p1.stdout, stdout=subprocess.PIPE)
+                    p2 = subprocess.Popen(
+                        [
+                            'ssh',
+                            '-o', 'StrictHostKeyChecking=no',
+                            '-t', '-t',
+                            str(rem),
+                            'sudo',
+                            'sh'
+                        ],
+                        stdin=p1.stdout, stdout=subprocess.PIPE
+                    )
                     _, err = p2.communicate()
                     if err:
                         log.info("Edit of /etc/sudoers failed: %s", err)