]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/tasks/cephadm.py: adjust client.admin key mode; place on all hosts
authorSage Weil <sage@newdream.net>
Mon, 26 Apr 2021 13:00:11 +0000 (09:00 -0400)
committerSage Weil <sage@newdream.net>
Tue, 27 Apr 2021 22:29:50 +0000 (18:29 -0400)
Except during upgrades, since it is not supported there.

Signed-off-by: Sage Weil <sage@newdream.net>
qa/suites/rados/cephadm/upgrade/1-start-distro/1-start-centos_8.3-octopus.yaml
qa/suites/rados/cephadm/upgrade/1-start-distro/1-start-ubuntu_20.04-15.2.9.yaml
qa/suites/rados/cephadm/upgrade/1-start-distro/1-start-ubuntu_20.04.yaml
qa/suites/upgrade/octopus-x/parallel/1-tasks.yaml
qa/suites/upgrade/octopus-x/stress-split/1-start.yaml
qa/tasks/cephadm.py

index f5441eb93e0a63e57a7c93ab17323d1e64e2338c..2e551dd439106a2e26ff175146f0f4cb7419c92d 100644 (file)
@@ -14,6 +14,7 @@ tasks:
     allow_ptrace: false
     # deploy additional mons the "old" (octopus) way
     add_mons_via_daemon_add: true
+    avoid_pacific_features: true
 
 
 roles:
index e60b8872d9fbbedba0e97a6beb12a0bf08d37cf1..fde68b32aa484339f532e527c2f0faf5171692a0 100644 (file)
@@ -10,6 +10,7 @@ tasks:
     allow_ptrace: false
     # deploy additional mons the "old" (octopus) way
     add_mons_via_daemon_add: true
+    avoid_pacific_features: true
 
 roles:
 - - mon.a
index 2af315930f29e65160018d997777b6a146a528be..983b4f3dc92bf95e86a43b05ceea0347748c5dd6 100644 (file)
@@ -10,6 +10,7 @@ tasks:
     allow_ptrace: false
     # deploy additional mons the "old" (octopus) way
     add_mons_via_daemon_add: true
+    avoid_pacific_features: true
 
 roles:
 - - mon.a
index b6bf1304fd220b5eaeb25b40630bfea1aa4f3951..ffa82cc522d688d86fe0a90589842abc2f62eae7 100644 (file)
@@ -14,6 +14,7 @@ tasks:
         osd_class_default_list: "*"
     # deploy additional mons the "old" (octopus) way
     add_mons_via_daemon_add: true
+    avoid_pacific_features: true
 - print: "**** done end installing octopus cephadm ..."
 
 - cephadm.shell:
index 432780592bfbf471a9914e95d74680e7d0204e68..7f01004a671e6b1c0bbce1c135102e8921cf4e1a 100644 (file)
@@ -13,6 +13,7 @@ tasks:
         osd_class_default_list: "*"
     # deploy additional mons the "old" (octopus) way
     add_mons_via_daemon_add: true
+    avoid_pacific_features: true
 
 - cephadm.shell:
     mon.a:
index f7113a6cad83863fd1993ed6b837018b57de559d..1092823a185a85f75af93efe82955bc5ffb8c674 100644 (file)
@@ -395,6 +395,8 @@ def ceph_bootstrap(ctx, config):
             cmd += ['--skip-monitoring-stack']
         if config.get('single_host_defaults'):
             cmd += ['--single-host-defaults']
+        if not config.get('avoid_pacific_features', False):
+            cmd += ['--skip-admin-label']
         # bootstrap makes the keyring root 0600, so +r it for our purposes
         cmd += [
             run.Raw('&&'),
@@ -435,10 +437,20 @@ def ceph_bootstrap(ctx, config):
             _shell(ctx, cluster_name, bootstrap_remote,
                    ['ceph', 'config', 'set', 'mgr', 'mgr/cephadm/allow_ptrace', 'true'])
 
+        if not config.get('avoid_pacific_features', False):
+            log.info('Distributing conf and client.admin keyring to all hosts + 0755')
+            _shell(ctx, cluster_name, bootstrap_remote,
+                   ['ceph', 'orch', 'client-keyring', 'set', 'client.admin',
+                    '*', '--mode', '0755'],
+                   check_status=False)
+
         # add other hosts
         for remote in ctx.cluster.remotes.keys():
             if remote == bootstrap_remote:
                 continue
+
+            # note: this may be redundant (see above), but it avoids
+            # us having to wait for cephadm to do it.
             log.info('Writing (initial) conf and keyring to %s' % remote.shortname)
             remote.write_file(
                 path='/etc/ceph/{}.conf'.format(cluster_name),