profile_grants.push_back(MonCapGrant("config-key delete", "key", StringConstraint("", prefix)));
}
if (profile == "bootstrap-osd") {
+ profile_grants.push_back(MonCapGrant("mon", MON_CAP_R)); // read monmap
+ profile_grants.push_back(MonCapGrant("osd", MON_CAP_R)); // read osdmap
profile_grants.push_back(MonCapGrant("mon getmap"));
profile_grants.push_back(MonCapGrant("osd create"));
profile_grants.push_back(MonCapGrant("osd crush set")); // FIXME: constraint this further?
profile_grants.back().command_args["caps_osd"] = StringConstraint("allow *", "");
}
if (profile == "bootstrap-mds") {
+ profile_grants.push_back(MonCapGrant("mon", MON_CAP_R)); // read monmap
+ profile_grants.push_back(MonCapGrant("osd", MON_CAP_R)); // read osdmap
profile_grants.push_back(MonCapGrant("mon getmap"));
profile_grants.push_back(MonCapGrant("auth get-or-create")); // FIXME: this can expose other mds keys
profile_grants.back().command_args["name"] = StringConstraint("", "mds.");