]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commit
mgr/smb: generate smb.conf hosts allow & hosts deny values
authorJohn Mulligan <jmulligan@redhat.com>
Mon, 22 Sep 2025 18:49:31 +0000 (14:49 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Fri, 16 Jan 2026 14:41:27 +0000 (09:41 -0500)
commitdddfc4e37359b570bcbbddda5ca5e2c5b45c87f9
tree0e79c0cc910e7e401359da3e224394a68b8caf07
parentd7b2217d322317571d7fba71b50a3e16565e2332
mgr/smb: generate smb.conf hosts allow & hosts deny values

Using the Share resource hosts_access parameter generate
smb.conf-equivalent configuration for the 'hosts allow' and 'hosts deny'
configuration parms. Note that currently we automatically set hosts deny
to all if *any* hosts allow is set to avoid the possibly surprising
result of explicitly setting hosts to allow and then having the share
continue to allow hosts not explicitly listed.

If needed, in the future we could allow the user to override the
default deny - but I'm trying to keep it real simple for now.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
src/pybind/mgr/smb/handler.py