]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cephadm: move configuration out of the way
authorJoao Eduardo Luis <joao@suse.com>
Thu, 31 Dec 2020 00:41:48 +0000 (00:41 +0000)
committerJoao Eduardo Luis <joao@suse.com>
Wed, 20 Jan 2021 14:20:45 +0000 (13:20 -0100)
Signed-off-by: Joao Eduardo Luis <joao@suse.com>
src/cephadm/cephadm

index 31c341ec16609749ca402286d4037e577e2e195b..27897d4c1ab0a1b0ba92c6ddae0624f4e0ba022d 100755 (executable)
@@ -3460,14 +3460,6 @@ def command_bootstrap(ctx):
         logger.info('Enabling IPv6 (ms_bind_ipv6)')
         cli(['config', 'set', 'global', 'ms_bind_ipv6', 'true'])
 
-    # create mgr
-    logger.info('Creating mgr...')
-    mgr_keyring = '[mgr.%s]\n\tkey = %s\n' % (mgr_id, mgr_key)
-    mgr_c = get_container(ctx, fsid, 'mgr', mgr_id)
-    # Note:the default port used by the Prometheus node exporter is opened in fw
-    deploy_daemon(ctx, fsid, 'mgr', mgr_id, mgr_c, uid, gid,
-                  config=config, keyring=mgr_keyring, ports=[9283])
-
     # output files
     with open(ctx.args.output_keyring, 'w') as f:
         os.fchmod(f.fileno(), 0o600)
@@ -3479,6 +3471,14 @@ def command_bootstrap(ctx):
         f.write(config)
     logger.info('Wrote config to %s' % ctx.args.output_config)
 
+    # create mgr
+    logger.info('Creating mgr...')
+    mgr_keyring = '[mgr.%s]\n\tkey = %s\n' % (mgr_id, mgr_key)
+    mgr_c = get_container(ctx, fsid, 'mgr', mgr_id)
+    # Note:the default port used by the Prometheus node exporter is opened in fw
+    deploy_daemon(ctx, fsid, 'mgr', mgr_id, mgr_c, uid, gid,
+                  config=config, keyring=mgr_keyring, ports=[9283])
+
     # wait for the service to become available
     logger.info('Waiting for mgr to start...')
     def is_mgr_available():