Only used by cephfs right now, so don't bother changing callers.
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
default_conf_path = '/etc/ceph/{cluster}.conf'.format(cluster=cluster_name)
conf_path = config.get('conf_path', default_conf_path)
log.info('Writing %s for FSID %s...' % (conf_path, fsid))
- write_conf(ctx, conf_path)
+ write_conf(ctx, conf_path, cluster_name)
log.info('Creating admin key on %s...' % firstmon)
ctx.cluster.only(firstmon).run(
log = logging.getLogger(__name__)
-def write_conf(ctx, conf_path=DEFAULT_CONF_PATH):
+def write_conf(ctx, conf_path=DEFAULT_CONF_PATH, cluster='ceph'):
conf_fp = StringIO()
- ctx.ceph.conf.write(conf_fp)
+ ctx.ceph[cluster].conf.write(conf_fp)
conf_fp.seek(0)
writes = ctx.cluster.run(
args=[