Call k8sclusterjuju.install with ensure future
[osm/LCM.git] / osm_lcm / ns.py
index 2534724..87eaecd 100644 (file)
@@ -1090,7 +1090,7 @@ class NsLcm(LcmBase):
                     step = "Install configuration Software, getting public ssh key"
                     pub_key = await self.n2vc.get_ee_ssh_public__key(ee_id=ee_id, db_dict=db_dict)
 
-                    step = "Insert public key into VM"
+                    step = "Insert public key into VM user={} ssh_key={}".format(user, pub_key)
                 else:
                     step = "Waiting to VM being up and getting IP address"
                 self.logger.debug(logging_text + step)
@@ -1673,9 +1673,11 @@ class NsLcm(LcmBase):
                                                         params=desc_params, db_dict=db_dict, timeout=3600)
                         )
                     else:
-                        task = self.k8sclusterjuju.install(cluster_uuid=cluster_uuid, kdu_model=kdumodel,
-                                                           atomic=True, params=desc_params,
-                                                           db_dict=db_dict, timeout=600)
+                        task = asyncio.ensure_future(
+                            self.k8sclusterjuju.install(cluster_uuid=cluster_uuid, kdu_model=kdumodel,
+                                                        atomic=True, params=desc_params,
+                                                        db_dict=db_dict, timeout=600)
+                        )
 
                     pending_tasks[task] = "_admin.deployed.K8s.{}.".format(index)
                     index += 1