Commit e6447bdc authored by Guillaume Abrioux's avatar Guillaume Abrioux
Browse files

library: do not always add --yes in batch mode

When asking `ceph-volume` to report only in `lvm batch` context, there's
a bug described in bz1896803 [1] when `--yes` is passed (which by the
way isn't necessary with `--report`).
This commit ensure `--yes` isn't passed to `ceph-volume` when `--report`
is used.



Signed-off-by: default avatarGuillaume Abrioux <>
(cherry picked from commit fe6d6ba6)
parent 0d072329
......@@ -275,7 +275,7 @@ def get_wal(wal, wal_vg):
return wal
def batch(module, container_image):
def batch(module, container_image, report=None):
Batch prepare OSD devices
......@@ -305,7 +305,8 @@ def batch(module, container_image):
action = ['lvm', 'batch']
cmd = build_cmd(action, container_image, cluster)
cmd.extend(['--%s' % objectstore])
if not report:
if container_image:
......@@ -666,7 +667,7 @@ def run_module():
cmd = batch(module, container_image)
cmd = batch(module, container_image, report=True)
batch_report_cmd = copy.copy(cmd)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment