]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
Fix installer.0 bug. 1141/head
authorWarren Usui <wusui@redhat.com>
Thu, 21 Dec 2017 03:03:03 +0000 (03:03 +0000)
committerWarren Usui <wusui@redhat.com>
Thu, 21 Dec 2017 03:03:03 +0000 (03:03 +0000)
Insure that mon node is used for rbd_pools.

Signed-off-by: Warren Usui <wusui@redhat.com>
teuthology/task/ceph_ansible.py

index 1a63fe02c73ea58c1d9708c9fdf87960b83c4a2e..e79d9ea291f5d4b4febf493979614a17be619776 100644 (file)
@@ -119,12 +119,14 @@ class CephAnsible(Task):
         # If there is an installer.0 node, use that for the installer.
         # Otherwise, use the first mon node as installer node.
         ansible_loc = self.ctx.cluster.only('installer.0')
+        (ceph_first_mon,) = self.ctx.cluster.only(
+            misc.get_first_mon(self.ctx,
+                               self.config)).remotes.iterkeys()
         if ansible_loc.remotes:
             (ceph_installer,) = ansible_loc.remotes.iterkeys()
         else:
-            (ceph_installer,) = self.ctx.cluster.only(
-                misc.get_first_mon(self.ctx,
-                                   self.config)).remotes.iterkeys()
+            ceph_installer = ceph_first_mon
+        self.ceph_first_mon = ceph_first_mon
         self.ceph_installer = ceph_installer
         self.args = args
         if self.config.get('rhbuild'):
@@ -480,7 +482,7 @@ class CephAnsible(Task):
             ceph_installer.run(args=('cat', 'ceph-ansible/group_vars/all'))
 
     def _create_rbd_pool(self):
-        mon_node = self.ceph_installer
+        mon_node = self.ceph_first_mon
         log.info('Creating RBD pool')
         mon_node.run(
             args=[