From: John Mulligan Date: Fri, 24 Nov 2023 19:45:34 +0000 (-0500) Subject: cephadm: call container daemon form prepare_data_dir X-Git-Tag: v20.0.0~2517^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=bf7e40b4d1fee439a4a7f48cf033d4a0885890d0;p=ceph.git cephadm: call container daemon form prepare_data_dir Instead of always climbing through an "if ladder" based on daemon type variables we will have the option of using the common method provided by container daemon form classes. This will initially be used by the smb daemon. I don't have the energy to refactor all the existing stuff at the moment. Signed-off-by: John Mulligan (cherry picked from commit 0f6a18a09cba35515e100f457e224537ad1e5608) --- diff --git a/src/cephadm/cephadm.py b/src/cephadm/cephadm.py index 5a7ed9e76656..4cdd52972faf 100755 --- a/src/cephadm/cephadm.py +++ b/src/cephadm/cephadm.py @@ -805,6 +805,11 @@ def create_daemon_dirs( node_proxy = NodeProxy.init(ctx, fsid, ident.daemon_id) node_proxy.create_daemon_dirs(data_dir, uid, gid) + else: + daemon = daemon_form_create(ctx, ident) + if isinstance(daemon, ContainerDaemonForm): + daemon.prepare_data_dir(data_dir, uid, gid) + _write_custom_conf_files(ctx, ident, uid, gid)