diff options
| author | Michal (inc0) Jastrzebski <inc007@gmail.com> | 2017-05-22 10:03:36 -0700 |
|---|---|---|
| committer | Michal (inc0) Jastrzebski <inc007@gmail.com> | 2017-06-19 10:14:33 -0700 |
| commit | 339b27c7fe2e95e8ae089adf66726b6adf42d9d5 (patch) | |
| tree | e6ec500812ca541e17754489e4eab3de0e61a4a6 /tests | |
| parent | ea5d1a581b1ed3d0f35a5cbc23f28e1e3e5ad9ec (diff) | |
| download | kolla-ansible-339b27c7fe2e95e8ae089adf66726b6adf42d9d5.tar.gz kolla-ansible-339b27c7fe2e95e8ae089adf66726b6adf42d9d5.zip | |
Enable multi-scenario gates
First non-trivial scenario we'll be testing in gates will be cinder +
ceph. This patchset is supposed to create framework to easily add new
testing scenarios.
Change-Id: I6790eaf5cf3297af04a64e4169a39b6e2cd1890f
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ansible_setup_ceph_disks.yml | 6 | ||||
| -rw-r--r-- | tests/setup_ceph_disks.sh | 13 | ||||
| -rw-r--r-- | tests/templates/globals-default.j2 | 5 |
3 files changed, 24 insertions, 0 deletions
diff --git a/tests/ansible_setup_ceph_disks.yml b/tests/ansible_setup_ceph_disks.yml new file mode 100644 index 000000000..6bde46d55 --- /dev/null +++ b/tests/ansible_setup_ceph_disks.yml @@ -0,0 +1,6 @@ +--- +- hosts: storage + tasks: + - name: "Setup loopbacks for ceph" + script: setup_ceph_disks.sh + register: ceph_disks_out diff --git a/tests/setup_ceph_disks.sh b/tests/setup_ceph_disks.sh new file mode 100644 index 000000000..2efb2042b --- /dev/null +++ b/tests/setup_ceph_disks.sh @@ -0,0 +1,13 @@ +mkdir -p /opt/data/kolla +dd if=/dev/zero of=/opt/data/kolla/ceph-osd0.img bs=5M count=3072 +LOOP=$(losetup -f) +losetup $LOOP /opt/data/kolla/ceph-osd0.img +parted $LOOP -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_OSD1 0 14GB + +dd if=/dev/zero of=/opt/data/kolla/ceph-journal0.img bs=5M count=1024 +LOOP=$(losetup -f) +losetup $LOOP /opt/data/kolla/ceph-journal0.img +parted $LOOP -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_OSD1_J 0 5GB + +partprobe $LOOP + diff --git a/tests/templates/globals-default.j2 b/tests/templates/globals-default.j2 index 3cc20580c..89f0432d8 100644 --- a/tests/templates/globals-default.j2 +++ b/tests/templates/globals-default.j2 @@ -19,3 +19,8 @@ enable_horizon: "yes" enable_heat: "no" openstack_logging_debug: "True" openstack_service_workers: "1" + +{% if 'ceph' in action %} +enable_ceph: "yes" +enable_cinder: "yes" +{% endif %} |
