Instead of printing out a traceback if adding the host fails
during bootstrapping process, should now print error message
telling user host failed to be added
Fixes: https://tracker.ceph.com/issues/45097
Signed-off-by: Adam King <adking@redhat.com>
(cherry picked from commit
0e2dd36aec24f54d51af5551a75a184fdefd325d)
host = get_hostname()
logger.info('Adding host %s...' % host)
- cli(['orch', 'host', 'add', host])
+ try:
+ cli(['orch', 'host', 'add', host])
+ except RuntimeError as e:
+ raise Error('Failed to add host <%s>: %s' % (host, e))
if not args.orphan_initial_daemons:
for t in ['mon', 'mgr', 'crash']: