Added a check for cloud-init completion before final ssh client check.