]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
python-common: add a new smb sub package
authorJohn Mulligan <jmulligan@redhat.com>
Wed, 13 Aug 2025 15:06:35 +0000 (11:06 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Fri, 15 Aug 2025 16:41:40 +0000 (12:41 -0400)
Add a new smb sub package for smb related things that are meant to
be shared throughout the Ceph python code related to smb and the
smb management stack.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
src/python-common/ceph/smb/__init__.py [new file with mode: 0644]
src/python-common/ceph/smb/constants.py [new file with mode: 0644]

diff --git a/src/python-common/ceph/smb/__init__.py b/src/python-common/ceph/smb/__init__.py
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/src/python-common/ceph/smb/constants.py b/src/python-common/ceph/smb/constants.py
new file mode 100644 (file)
index 0000000..bc2961d
--- /dev/null
@@ -0,0 +1,49 @@
+# Shared constant values that apply across all ceph components that manage
+# smb services (mgr module, cephadm mgr module, cephadm binary, etc)
+
+
+# Generic/common names
+SMB = 'smb'
+CTDB = 'ctdb'
+
+
+# Feature names
+CEPHFS_PROXY = 'cephfs-proxy'
+CLUSTERED = 'clustered'
+DOMAIN = 'domain'
+REMOTE_CONTROL = 'remote-control'
+SMBMETRICS = 'smbmetrics'
+
+
+# Features are optional components that can be deployed in a suite of smb
+# related containers. It may run as a separate sidecar or side-effect the
+# configuration of another component.
+FEATURES = {
+    CEPHFS_PROXY,
+    CLUSTERED,
+    DOMAIN,
+    REMOTE_CONTROL,
+}
+
+# Services are components that listen on a "public" network port, to expose
+# network services to remote clients.
+SERVICES = {
+    CTDB,
+    REMOTE_CONTROL,
+    SMB,
+    SMBMETRICS,
+}
+
+
+# Default port values
+SMB_PORT = 445
+SMBMETRICS_PORT = 9922
+CTDB_PORT = 4379
+REMOTE_CONTROL_PORT = 54445
+
+DEFAULT_PORTS = {
+    SMB: SMB_PORT,
+    SMBMETRICS: SMBMETRICS_PORT,
+    CTDB: CTDB_PORT,
+    REMOTE_CONTROL: REMOTE_CONTROL_PORT,
+}