osd: do not use expose_partitions on lvm

expose_partitions is only needed on ceph-disk OSDs so we don't need to
activate this code when running lvm prepared OSDs.

Signed-off-by: Sébastien Han <seb@redhat.com>
pull/3220/head
Sébastien Han 2018-09-28 17:19:46 +02:00 committed by Guillaume Abrioux
parent e39fc4f6ce
commit ece9e9812e
1 changed files with 2 additions and 0 deletions

View File

@ -11,6 +11,7 @@ DOCKER_ENV=""
#############
# FUNCTIONS #
#############
{% if osd_scenario != 'lvm' -%}
{% if disk_list.get('rc') == 0 -%}
function expose_partitions () {
DOCKER_ENV=$(docker run --rm --net=host --name expose_partitions_${1} --privileged=true -v /dev/:/dev/ -v /etc/ceph:/etc/ceph:z -e CLUSTER={{ cluster }} -e OSD_DEVICE=/dev/${1} {{ ceph_docker_registry }}/{{ ceph_docker_image }}:{{ ceph_docker_image_tag }} disk_list)
@ -52,6 +53,7 @@ function expose_partitions {
fi
}
{% endif -%}
{% endif -%}
expose_partitions "$1"