- deploy(vnf_index, vdu["id"], db_vnfrs[vnf_index]["vdur"][vdu_index]["ip-address"],
- n2vc_info, config_primitive)
+ vdur = db_vnfrs[vnf_index]["vdur"][vdu_index]
+ # TODO for the moment only first vdu_id contains a charm deployed
+ if vdur["vdu-id-ref"] != vdu["id"]:
+ raise LcmException("Mismatch vdur {}, vdu {} at index {} for vnf {}"
+ .format(vdur["vdu-id-ref"], vdu["id"], vdu_index, vnf_index))
+ deploy_charm(vnf_index, vdu["id"], vdur.get("name"), vdur["count-index"],
+ vdur["ip-address"], n2vc_info, config_primitive)