Fix update hang.

Don't check ssh keys of VM (attempting to update them) if we are
changing the state of the host (up/down) as there is a good chance
it will be down and will never return any keys.

Signed-off-by: Sandon Van Ness <sandon@inktank.com>
+        status_info = get_status(name)
+        if status_info['is_vm']:
+            ssh_key = None
+            while not ssh_key:
+                time.sleep(10)
+                ssh_key = ssh_keyscan([name])

I forgot why this was happening, but once upon a time ssh_keyscan returned None in some cases on vms at first, but then would do so later.  This code looped until ssh_keyscan returned something valid (ssh_key is tested in the while statement).

The problem here may be a race condition or timing issue for which there is a better solution, but I think waiting to get a valid key was the motivation for this code.