]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/dashboard: enable ha by default on subsystem POST API 62623/head
authorNizamudeen A <nia@redhat.com>
Tue, 1 Apr 2025 08:31:28 +0000 (14:01 +0530)
committerNizamudeen A <nia@redhat.com>
Wed, 2 Apr 2025 05:44:26 +0000 (11:14 +0530)
Fixes: https://tracker.ceph.com/issues/70745
Signed-off-by: Nizamudeen A <nia@redhat.com>
(cherry picked from commit 4ae817f703560232e96c0d58ae76a9e194e20996)

src/pybind/mgr/dashboard/controllers/nvmeof.py
src/pybind/mgr/dashboard/openapi.yaml

index 9e22d0698611f2ed5d6152ff43c789e56ffdf081..323996b245d5c62bfecd46a62c0a74b46641dac6 100644 (file)
@@ -157,7 +157,7 @@ else:
         )
         @empty_response
         @handle_nvmeof_error
-        def create(self, nqn: str, enable_ha: bool, max_namespaces: int = 1024,
+        def create(self, nqn: str, enable_ha: bool = True, max_namespaces: int = 1024,
                    gw_group: Optional[str] = None):
             return NVMeoFClient(gw_group=gw_group).stub.create_subsystem(
                 NVMeoFClient.pb2.create_subsystem_req(
index f309fea6f872d6c81964b99e5135a485291f1627..9a01318057723fc23ef2c8a5949dccf29c45f755 100644 (file)
@@ -8099,6 +8099,7 @@ paths:
             schema:
               properties:
                 enable_ha:
+                  default: true
                   description: Enable high availability
                   type: boolean
                 gw_group:
@@ -8113,7 +8114,6 @@ paths:
                   type: string
               required:
               - nqn
-              - enable_ha
               type: object
       responses:
         '201':