]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
tests: Update ooo-collocation scenario
authorDimitri Savineau <dsavinea@redhat.com>
Mon, 29 Jul 2019 18:47:49 +0000 (14:47 -0400)
committerGuillaume Abrioux <gabrioux@redhat.com>
Tue, 30 Jul 2019 06:27:13 +0000 (08:27 +0200)
The ooo-collocation scenario was still using an old container image and
doesn't match the requirement on latest stable-3.2 code. We need to use
at least the container image v3.2.5.
Also updating the OSD tests to reflect the changes introduced by the
commit bedc0ab because we don't have the OSD systemd unit script using
device name anymore.

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
tests/functional/ooo-collocation/hosts
tests/functional/tests/osd/test_osds.py
tox.ini

index ae671a1be2d837977c7fb41f872949714a5bdb02..388298af8e64f6e39aff899c3ea47df5ba01ed3d 100644 (file)
@@ -10,7 +10,7 @@ all:
     ceph_mgr_docker_extra_env: '-e MGR_DASHBOARD=0'
     cluster: mycluster
     ceph_docker_image: ceph/daemon
-    ceph_docker_image_tag: v3.0.3-stable-3.0-luminous-centos-7-x86_64
+    ceph_docker_image_tag: v3.2.5-stable-3.2-luminous-centos-7
     ceph_docker_registry: docker.io
     ceph_origin: repository
     ceph_repository: community
index d7a011c324fbd7d6922a82f9ed1ae5c3f2232d0e..36aa8958448cf90fe3ec4152b5dd6b4c5b8aff76 100644 (file)
@@ -7,25 +7,9 @@ class TestOSDs(object):
 
     def _get_osds_id(self, node, host):
         osds = []
-        if node['rolling_update'] and node['docker']:
-            cmd = host.run('sudo docker exec {osd_id} ceph-disk list --format json'.format(osd_id=self._get_docker_exec_cmd(host)))
-            ceph_disk_list = json.loads(cmd.stdout)
-            for device in ceph_disk_list:
-                if 'partitions' in device.keys():
-                    for partition in device['partitions']:
-                        if 'type' in partition.keys() and partition['type'] == 'data':
-                            osds.append(device['path'].split('/')[-1])
-        else:
-            cmd = host.run('sudo ls /var/lib/ceph/osd/ | sed "s/.*-//"')
-            if cmd.rc == 0:
-                osd_ids = cmd.stdout.rstrip("\n").split("\n")
-                osds = osd_ids
-                if node['docker'] and node['fsid'] == "6e008d48-1661-11e8-8546-008c3214218a":
-                    osds = []
-                    for device in node['devices']:
-                        real_dev = host.run("sudo readlink -f %s" % device)
-                        real_dev_split = real_dev.stdout.split("/")[-1]
-                        osds.append(real_dev_split)
+        cmd = host.run('sudo ls /var/lib/ceph/osd/ | sed "s/.*-//"')
+        if cmd.rc == 0:
+            osds = cmd.stdout.rstrip("\n").split("\n")
         return osds
 
     def _get_docker_exec_cmd(self, host):
diff --git a/tox.ini b/tox.ini
index 7ce362fc392bda01afee6cb6368e2441642adbed..1c80ce8ba1a546b107c88ecac9547b71deaeb51d 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -205,7 +205,7 @@ setenv=
   rhcs: CEPH_STABLE_RELEASE = luminous
   lvm_osds: CEPH_STABLE_RELEASE = luminous
   rhcs: CEPH_STABLE_RELEASE = luminous
-  ooo_collocation: CEPH_DOCKER_IMAGE_TAG = v3.0.3-stable-3.0-luminous-centos-7-x86_64
+  ooo_collocation: CEPH_DOCKER_IMAGE_TAG = v3.2.5-stable-3.2-luminous-centos-7
 
 deps= -r{toxinidir}/tests/requirements.txt
 changedir=