From: garciadeblas Date: Mon, 23 Sep 2024 10:40:13 +0000 (+0200) Subject: Update VIM operational state after successful ODU workflow X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=15b8a30111470e4e93099c987875fb273b7dbd60;p=osm%2FLCM.git Update VIM operational state after successful ODU workflow Change-Id: If29bf096c2a82b937f38d20c749a1f439d5faa5b Signed-off-by: garciadeblas --- diff --git a/osm_lcm/k8s.py b/osm_lcm/k8s.py index 381195c..ab6652a 100644 --- a/osm_lcm/k8s.py +++ b/osm_lcm/k8s.py @@ -589,6 +589,14 @@ class CloudCredentialsLcm(LcmBase): resource_status, resource_msg ) ) + + content["_admin"]["operationalState"] = "ENABLED" + for operation in content["_admin"]["operations"]: + if operation["lcmOperationType"] == "create": + operation["operationState"] = "ENABLED" + self.logger.info("Content : {}".format(content)) + self.db.set_one("vim_accounts", {"_id": content["_id"]}, content) + return async def edit(self, op_id, op_params, content):