X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=osm_lcm%2Fns.py;h=193cab60876b52d5836947254d7f4d4ed58a912c;hb=c61e7813da16b2dc42d7ca4f625efe720096ab54;hp=a5a67301d1e1d5bfb3a2beb9ee42c84d9c443e9a;hpb=3bedc9bf2cf602bd3a67ba699d60ea49539ae9e5;p=osm%2FLCM.git diff --git a/osm_lcm/ns.py b/osm_lcm/ns.py index a5a6730..193cab6 100644 --- a/osm_lcm/ns.py +++ b/osm_lcm/ns.py @@ -907,9 +907,9 @@ class NsLcm(LcmBase): for vdur in get_iterable(db_vnfr, "vdur"): if (vdur["vdu-id-ref"] == vdu_id and vdur["count-index"] == vdu_index) or \ (ip_address and vdur.get("ip-address") == ip_address): - if vdur["status"] == "ACTIVE": + if vdur.get("status") == "ACTIVE": target_vdu_id = vdur["vdu-id-ref"] - elif vdur["status"] == "ERROR": + elif vdur.get("status") == "ERROR": raise LcmException("Cannot inject ssh-key because target VM is in error state") break else: