From: Dimitri Savineau Date: Thu, 16 Apr 2020 20:30:27 +0000 (-0400) Subject: cephadm: fix adopt prometheus command X-Git-Tag: v16.1.0~2529^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F34600%2Fhead;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 6031e2535e88..6a766e1fc774 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