mirror of
https://github.com/ceph/ceph
synced 2025-02-19 08:57:27 +00:00
rbd-ggate: honor rbd_default_pool config setting
Signed-off-by: Mykola Golub <to.my.trociny@gmail.com>
This commit is contained in:
parent
2113ebe02d
commit
412a3c4cb6
@ -47,7 +47,7 @@ static void usage() {
|
||||
generic_server_usage();
|
||||
}
|
||||
|
||||
static std::string devpath, poolname("rbd"), imgname, snapname;
|
||||
static std::string devpath, poolname, imgname, snapname;
|
||||
static bool readonly = false;
|
||||
static bool exclusive = false;
|
||||
|
||||
@ -106,6 +106,10 @@ static int do_map(int argc, const char *argv[])
|
||||
common_init_finish(g_ceph_context);
|
||||
global_init_chdir(g_ceph_context);
|
||||
|
||||
if (poolname.empty()) {
|
||||
poolname = g_ceph_context->_conf->get_val<std::string>("rbd_default_pool");
|
||||
}
|
||||
|
||||
std::string devname = (devpath.compare(0, 5, "/dev/") == 0) ?
|
||||
devpath.substr(5) : devpath;
|
||||
std::unique_ptr<rbd::ggate::Watcher> watcher;
|
||||
|
Loading…
Reference in New Issue
Block a user