From: Shwetha K Acharya Date: Wed, 21 May 2025 11:20:53 +0000 (+0530) Subject: mgr/smb: Add new configs to share definition X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=74288183964c4d02a7528ab9fdf21c518930b401;p=ceph.git mgr/smb: Add new configs to share definition Inorder to support Microsoft Management Console (MMC) plugin feature, ceph manager must handle all fields supported by `add share command` and related smb.conf options. Added "comment" and "max connections" entries to the Samba configuration generated by the Ceph Manager module. These fields are required for MMC integration and will be made configurable in a future update. Signed-off-by: Shwetha K Acharya --- diff --git a/qa/suites/orch/cephadm/smb/tasks/deploy_smb_basic.yaml b/qa/suites/orch/cephadm/smb/tasks/deploy_smb_basic.yaml index d92ccad96f258..cb5c78d514fd9 100644 --- a/qa/suites/orch/cephadm/smb/tasks/deploy_smb_basic.yaml +++ b/qa/suites/orch/cephadm/smb/tasks/deploy_smb_basic.yaml @@ -51,6 +51,8 @@ tasks: "kernel share modes" = "no" "read only" = "no" "browseable" = "yes" + "comment" = "" + "max connections" = "0" [globals.default.options] "load printers" = "no" "printing" = "bsd" diff --git a/qa/suites/orch/cephadm/smb/tasks/deploy_smb_domain.yaml b/qa/suites/orch/cephadm/smb/tasks/deploy_smb_domain.yaml index c8c91f908df37..9f93c740a8e7a 100644 --- a/qa/suites/orch/cephadm/smb/tasks/deploy_smb_domain.yaml +++ b/qa/suites/orch/cephadm/smb/tasks/deploy_smb_domain.yaml @@ -50,6 +50,8 @@ tasks: "kernel share modes" = "no" "read only" = "no" "browseable" = "yes" + "comment" = "" + "max connections" = "0" [globals.default.options] "load printers" = "no" "printing" = "bsd" diff --git a/src/pybind/mgr/smb/handler.py b/src/pybind/mgr/smb/handler.py index e0dc951890252..73e635521bb18 100644 --- a/src/pybind/mgr/smb/handler.py +++ b/src/pybind/mgr/smb/handler.py @@ -1196,6 +1196,8 @@ def _generate_share( 'browseable': ynbool(share.browseable), 'kernel share modes': 'no', 'x:ceph:id': f'{share.cluster_id}.{share.share_id}', + 'comment': '', + 'max connections': '0', } } if proxy_val: