From: garciadeblas Date: Tue, 5 Aug 2025 07:15:33 +0000 (+0200) Subject: Feature 11057: Cluster management in Openshift-based infrastructures X-Git-Tag: v18.0.0~3 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=616d4c7e12c19c19702dd2120b57a9385ea8e4f8;p=osm%2FNBI.git Feature 11057: Cluster management in Openshift-based infrastructures Change-Id: I2ff2f415b0d45e096b9f2f00dcb9b4015a8c8b52 Signed-off-by: garciadeblas --- diff --git a/osm_nbi/k8s_topics.py b/osm_nbi/k8s_topics.py index dc6016c..89f8031 100644 --- a/osm_nbi/k8s_topics.py +++ b/osm_nbi/k8s_topics.py @@ -328,8 +328,7 @@ class ClusterTopic(ACMTopic): "vim_accounts", {"name": content["vim_account"]} ) - # Add optional fields if they exist in the request - + # Add optional fields if they don't exist in the request if "region_name" not in indata: region_name = vim_account_details.get("config", {}).get("region_name") if region_name: @@ -342,10 +341,12 @@ class ClusterTopic(ACMTopic): version = "k8s_version" in content if not version: - content["k8s_version"] = "1.28" + content["k8s_version"] = "1.32" + # Additional cluster information, specific for each cluster type + content["config"] = indata.get("config", {}) content["node_count"] = indata.get("node_count", 0) content["ksu_count"] = 0 - self.logger.info(f"cotent is : {content}") + self.logger.info(f"content is : {content}") return content def check_vim(self, session, name): @@ -896,6 +897,7 @@ class ClusterOpsTopic(ACMTopic): "credentials": cls_add_request["credentials"], "vim_account": cls_add_request["vim_account"], "bootstrap": cls_add_request["bootstrap"], + "openshift": cls_add_request.get("openshift", False), "infra_controller_profiles": [ self._create_default_profiles( rollback, session, indata, kwargs, headers, self.infra_contr_topic