summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2018-07-28 19:01:44 +0300
committerLars Wirzenius <liw@liw.fi>2018-07-28 19:01:44 +0300
commit9ae1649ad1570734a6c5431e58ea9574efa52d5a (patch)
treea6f196c6d5331db83ee795cba3f137618a9f6791
parentff43337a9ec55023aefa997197df4cdf4b7d5b79 (diff)
downloadvmdb2-9ae1649ad1570734a6c5431e58ea9574efa52d5a.tar.gz
Add: depend on qemu-utils (for qemu-img)
-rw-r--r--debian/changelog3
-rw-r--r--debian/control2
-rw-r--r--vmdb/plugins/grub_plugin.py7
3 files changed, 9 insertions, 3 deletions
diff --git a/debian/changelog b/debian/changelog
index 4821e80..9becb6b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,8 +1,9 @@
vmdb2 (0.13.2+git-1) UNRELEASED; urgency=medium
* New upstream version.
- * Drop build-dependncy on pylint3, which doesn't install in Debian
+ * Drop build-dependency on pylint3, which doesn't install in Debian
unstable at this time. Will put it back when it does.
+ * Add dependency and build-dependency on qemu-utils, for qemu-img.
-- Lars Wirzenius <liw@liw.fi> Sun, 06 May 2018 09:26:25 +0300
diff --git a/debian/control b/debian/control
index d6e6cba..6861d67 100644
--- a/debian/control
+++ b/debian/control
@@ -13,6 +13,7 @@ Build-Depends: debhelper (>= 9),
cmdtest,
python3-yaml,
debootstrap,
+ qemu-utils,
parted,
kpartx
@@ -25,6 +26,7 @@ Depends: ${python3:Depends}, ${misc:Depends},
python3-yaml,
cmdtest,
debootstrap,
+ qemu-utils,
parted,
kpartx
Recommends: ansible
diff --git a/vmdb/plugins/grub_plugin.py b/vmdb/plugins/grub_plugin.py
index 80b599a..3cc431c 100644
--- a/vmdb/plugins/grub_plugin.py
+++ b/vmdb/plugins/grub_plugin.py
@@ -189,9 +189,12 @@ class GrubStepRunner(vmdb.StepRunnerInterface):
def get_image_loop_device(self, partition_device):
# We get /dev/mappers/loopXpY and return /dev/loopX
- assert partition_device.startswith('/dev/mapper/loop')
+ # assert partition_device.startswith('/dev/mapper/loop')
- m = re.match(r'^/dev/mapper/(?P<loop>loop\d+)p\d+$', partition_device)
+ m = re.match(r'^/dev/mapper/(?P<loop>.*)p\d+$', partition_device)
+ if m is None:
+ raise Exception('Do not understand partitio device name {}'.format(
+ partition_device))
assert m is not None
loop = m.group('loop')