[lxc-devel] [lxd/master] lxd/storage/utils: Removes duplicated qemu-img call in ImageUnpack
tomponline on Github
lxc-bot at linuxcontainers.org
Thu May 28 11:25:08 UTC 2020
A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 361 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20200528/aa9ce3e1/attachment-0001.bin>
-------------- next part --------------
From deef1786e9d93037c366bf24de5ffc82f467bd20 Mon Sep 17 00:00:00 2001
From: Thomas Parrott <thomas.parrott at canonical.com>
Date: Thu, 28 May 2020 12:20:59 +0100
Subject: [PATCH] lxd/storage/utils: Removes duplicated qemu-img call in
ImageUnpack
Signed-off-by: Thomas Parrott <thomas.parrott at canonical.com>
---
lxd/storage/utils.go | 6 ------
1 file changed, 6 deletions(-)
diff --git a/lxd/storage/utils.go b/lxd/storage/utils.go
index e4b0d2f146..8e0c2b3107 100644
--- a/lxd/storage/utils.go
+++ b/lxd/storage/utils.go
@@ -576,12 +576,6 @@ func ImageUnpack(imageFile string, vol drivers.Volume, destBlockFile string, blo
if err != nil {
return -1, err
}
-
- // Convert the qcow2 format to a raw block device.
- _, err = shared.RunCommand("qemu-img", "convert", "-O", "raw", imageRootfsFile, destBlockFile)
- if err != nil {
- return -1, fmt.Errorf("Failed converting image to raw at %s: %v", destBlockFile, err)
- }
} else {
// Dealing with unified tarballs require an initial unpack to a temporary directory.
tempDir, err := ioutil.TempDir(shared.VarPath("images"), "lxd_image_unpack_")
More information about the lxc-devel
mailing list