Add openshift boolean field to cluster registration schema; minor rename of schemas 03/15403/1
authorgarciadeblas <gerardo.garciadeblas@telefonica.com>
Mon, 15 Sep 2025 13:42:15 +0000 (15:42 +0200)
committergarciadeblas <gerardo.garciadeblas@telefonica.com>
Wed, 17 Sep 2025 09:31:29 +0000 (11:31 +0200)
Change-Id: I8a8f6ca4a7b0bf2a838ae6e94eae3027beef81bf
Signed-off-by: garciadeblas <gerardo.garciadeblas@telefonica.com>
osm_nbi/k8s_topics.py
osm_nbi/validation.py

index 7d8ffb8..23faf29 100644 (file)
@@ -27,7 +27,7 @@ from osm_nbi.descriptor_topics import DescriptorTopic
 from osm_nbi.validation import (
     ValidationError,
     validate_input,
-    clustercreation_new_schema,
+    cluster_creation_new_schema,
     cluster_edit_schema,
     cluster_update_schema,
     infra_controller_profile_create_new_schema,
@@ -38,7 +38,7 @@ from osm_nbi.validation import (
     infra_config_profile_create_edit_schema,
     app_profile_create_edit_schema,
     resource_profile_create_edit_schema,
-    clusterregistration_new_schema,
+    cluster_registration_new_schema,
     attach_dettach_profile_schema,
     ksu_schema,
     app_instance_schema,
@@ -155,7 +155,7 @@ class ResourceTopic(ProfileTopic):
 class ClusterTopic(ACMTopic):
     topic = "clusters"
     topic_msg = "cluster"
-    schema_new = clustercreation_new_schema
+    schema_new = cluster_creation_new_schema
     schema_edit = attach_dettach_profile_schema
 
     def __init__(self, db, fs, msg, auth):
@@ -823,7 +823,7 @@ class NodeGroupTopic(ACMTopic):
 class ClusterOpsTopic(ACMTopic):
     topic = "clusters"
     topic_msg = "cluster"
-    schema_new = clusterregistration_new_schema
+    schema_new = cluster_registration_new_schema
 
     def __init__(self, db, fs, msg, auth):
         super().__init__(db, fs, msg, auth)
index 349ca05..e31b523 100644 (file)
@@ -1092,7 +1092,7 @@ vnfpkgop_new_schema = {
     "additionalProperties": False,
 }
 
-clustercreation_new_schema = {
+cluster_creation_new_schema = {
     "$schema": "http://json-schema.org/draft-07/schema#",
     "title": "cluster creation operation input schema",
     "type": "object",
@@ -1134,7 +1134,7 @@ clustercreation_new_schema = {
     "additionalProperties": False,
 }
 
-clusterregistration_new_schema = {
+cluster_registration_new_schema = {
     "title": "cluster registration input schema",
     "$schema": "http://json-schema.org/draft-04/schema#",
     "type": "object",
@@ -1146,6 +1146,7 @@ clusterregistration_new_schema = {
         "credentials": object_schema,
         "vim_account": string_schema,
         "bootstrap": bool_schema,
+        "openshift": bool_schema,
     },
     "required": ["name", "credentials", "vim_account"],
     "additionalProperties": False,