]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
mgr/orchestrator: require "group" field for nvmeof specs
authorAdam King <adking@redhat.com>
Thu, 25 Jul 2024 17:35:35 +0000 (13:35 -0400)
committerAlexander Indenbaum <aindenba@redhat.com>
Wed, 19 Nov 2025 18:41:52 +0000 (20:41 +0200)
Signed-off-by: Adam King <adking@redhat.com>
(cherry picked from commit f6d552d7c777f1160545188dcffa6b685b05ca8a)

src/python-common/ceph/deployment/service_spec.py

index 26225d6b01447b38616a4c449ebfe1b3abb1fca6..d1c9d3c983f9450de17fbd5ca0db601bafe05849 100644 (file)
@@ -1382,7 +1382,7 @@ class NvmeofServiceSpec(ServiceSpec):
         #: ``name`` name of the nvmeof gateway
         self.name = name
         #: ``group`` name of the nvmeof gateway
-        self.group = group or ''
+        self.group = group
         #: ``enable_auth`` enables user authentication on nvmeof gateway
         self.enable_auth = enable_auth
         #: ``state_update_notify`` enables automatic update from OMAP in nvmeof gateway
@@ -1474,6 +1474,9 @@ class NvmeofServiceSpec(ServiceSpec):
         if not self.pool:
             raise SpecValidationError('Cannot add NVMEOF: No Pool specified')
 
+        if not self.group:
+            raise SpecValidationError('Cannot add NVMEOF: No group specified')
+
         if self.enable_auth:
             if not all([self.server_key, self.server_cert, self.client_key,
                         self.client_cert, self.root_ca_cert]):