From: Dimitri Savineau Date: Thu, 16 Apr 2020 20:30:27 +0000 (-0400) Subject: cephadm: fix adopt prometheus command X-Git-Tag: v17.0.0~2561^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=252d4b3044b999e22e46845d3f7c7641e858ed31;p=ceph.git cephadm: fix adopt prometheus command Create the target directory before copy the prometheus configuration. Closes: https://tracker.ceph.com/issues/45120 Signed-off-by: Dimitri Savineau --- diff --git a/src/cephadm/cephadm b/src/cephadm/cephadm index 6031e2535e88b..6a766e1fc774d 100755 --- a/src/cephadm/cephadm +++ b/src/cephadm/cephadm @@ -3241,6 +3241,7 @@ def command_adopt_prometheus(daemon_id, fsid): config_src = '/etc/prometheus/prometheus.yml' config_src = os.path.abspath(args.legacy_dir + config_src) config_dst = os.path.join(data_dir_dst, 'etc/prometheus') + makedirs(config_dst, uid, gid, 0o755) copy_files([config_src], config_dst, uid=uid, gid=gid) # data