Use paramiko.AutoAddPolicy for the smoketests.
Updates the Nova smoketests so that we use Paramiko's auto add ssh key policy. This should help quiet down warnings like this which we previously got when running the EC2 smoketests with Nova: /usr/lib/python2.7/site-packages/paramiko/client.py:95: UserWarning: Unknown ssh-rsa host key for 172.20.0.3: adb1c2f1fe461a35cd01283eac03d6fb Fixes LP Bug #1064550. Change-Id: I1611a3f6b54563b6a1d64c4f8e193a636ccb1c69
This commit is contained in:
parent
36b85251ab
commit
ea3f31b7e9
|
@ -41,7 +41,7 @@ class SmokeTestCase(unittest.TestCase):
|
|||
while(True):
|
||||
try:
|
||||
client = paramiko.SSHClient()
|
||||
client.set_missing_host_key_policy(paramiko.WarningPolicy())
|
||||
client.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||
client.connect(ip, username='root', pkey=key, timeout=5)
|
||||
return client
|
||||
except (paramiko.AuthenticationException, paramiko.SSHException):
|
||||
|
|
Loading…
Reference in New Issue