From: Adam King Date: Mon, 7 Apr 2025 20:04:49 +0000 (-0400) Subject: mgr/nfs: make sure sectype is a list when parsed X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=dda7da63d48012ff61715633aa0d333550e9747b;p=ceph.git mgr/nfs: make sure sectype is a list when parsed Signed-off-by: Adam King (cherry picked from commit f931921f2f95181550a775496d14b279beb15f3c) --- diff --git a/src/pybind/mgr/nfs/ganesha_conf.py b/src/pybind/mgr/nfs/ganesha_conf.py index 5108222eef311..e4cff653d250e 100644 --- a/src/pybind/mgr/nfs/ganesha_conf.py +++ b/src/pybind/mgr/nfs/ganesha_conf.py @@ -413,6 +413,11 @@ class Export: # accept "sectype" too. sectype = (export_block.values.get("SecType") or export_block.values.get("sectype") or None) + # If sectype was only a single value (e.g. "sys") we end + # up with a string instead of a list of strings here + # https://github.com/ceph/go-ceph/issues/1097 + if sectype is not None and not isinstance(sectype, list): + sectype = [sectype] return cls(export_block.values['export_id'], export_block.values['path'], cluster_id,