Merge pull request #1132 from flatcar/scripts

Allow use qcow2 inline compression
This commit is contained in:
Kai Lueke 2023-09-26 13:41:21 +02:00
commit 4b71b330c8
2 changed files with 3 additions and 1 deletions

View File

@ -555,7 +555,7 @@ _write_raw_disk() {
}
_write_qcow2_disk() {
qemu-img convert -f raw "$1" -O qcow2 -o compat=0.10 "$2"
qemu-img convert -f raw "$1" -O qcow2 -c -o compat=0.10 "$2"
assert_image_size "$2" qcow2
}

View File

@ -119,6 +119,8 @@ function _vm_build_impl() {
COMPRESSION_FORMAT="bz2"
if [[ "${format}" =~ ^(openstack|openstack_mini|digitalocean)$ ]];then
COMPRESSION_FORMAT="gz,bz2"
elif [[ "${format}" =~ ^(qemu|qemu_uefi)$ ]];then
COMPRESSION_FORMAT="bz2,none"
fi
./run_sdk_container -n "${vms_container}" -C "${packages_image}" \
-v "${vernum}" \