From 591d77220e4e8fef12faf4312ec977c3e175ed09 Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Thu, 9 Nov 2017 11:05:59 +0100 Subject: [PATCH] osd: always run disk_list test there is no need to have a condition on this task, this test should be always run since the result will be interpreted later. Signed-off-by: Guillaume Abrioux --- roles/ceph-osd/tasks/docker/start_docker_osd.yml | 2 -- roles/ceph-osd/templates/ceph-osd-run.sh.j2 | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/roles/ceph-osd/tasks/docker/start_docker_osd.yml b/roles/ceph-osd/tasks/docker/start_docker_osd.yml index ec62f24eb..4960b9ed8 100644 --- a/roles/ceph-osd/tasks/docker/start_docker_osd.yml +++ b/roles/ceph-osd/tasks/docker/start_docker_osd.yml @@ -15,8 +15,6 @@ changed_when: false failed_when: false register: disk_list - when: - - ceph_release_num[ceph_release] < ceph_release_num.kraken - name: generate ceph osd docker run script become: true diff --git a/roles/ceph-osd/templates/ceph-osd-run.sh.j2 b/roles/ceph-osd/templates/ceph-osd-run.sh.j2 index 724d4bfb9..11f8df852 100644 --- a/roles/ceph-osd/templates/ceph-osd-run.sh.j2 +++ b/roles/ceph-osd/templates/ceph-osd-run.sh.j2 @@ -5,7 +5,7 @@ ############# # FUNCTIONS # ############# -{% if disk_list.get("rc", 1) == 0 -%} +{% if disk_list.get('rc') == 0 -%} function expose_partitions () { DOCKER_ENV=$(docker run --rm --name expose_partitions_${1} --privileged=true -v /dev/:/dev/ -v /etc/ceph:/etc/ceph -e CLUSTER={{ cluster }} -e OSD_DEVICE=/dev/${1} {{ ceph_docker_registry }}/{{ ceph_docker_image }}:{{ ceph_docker_image_tag }} disk_list) docker rm -f expose_partitions_${1}