]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commit
ceph-volume: be idempotent when the batch strategy changes
authorAndrew Schoen <aschoen@redhat.com>
Tue, 20 Nov 2018 20:28:58 +0000 (14:28 -0600)
committermergify[bot] <mergify[bot]@users.noreply.github.com>
Tue, 27 Nov 2018 00:23:21 +0000 (00:23 +0000)
commit59524c7246e2ab1ed534342076c21b02bf3df30d
tree2ab45cbc59d02ae07800b681c1e52b0a8e0d0fd4
parent1a1886a4429613b1dacd3e238c7c5dda3255800f
ceph-volume: be idempotent when the batch strategy changes

If you deploy with 2 HDDs and 1 SDD then each subsequent deploy both
HDD drives will be filtered out, because they're already used by ceph.
ceph-volume will report this as a 'strategy change' because the device
list went from a mixed type of HDD and SDD to a single type of only SDD.

This situation results in a non-zero exit code from ceph-volume. We want
to handle this situation gracefully and report that nothing will be changed.
A similar json structure to what would have been given by ceph-volume is
returned in the 'stdout' key.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1650306
Signed-off-by: Andrew Schoen <aschoen@redhat.com>
(cherry picked from commit e13f32c1c5be2e4007714f704297827b16488ec6)
library/ceph_volume.py