mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-01-04 13:07:00 -06:00
a94ce0d7b6
Since version 8 of qemu-img tool it produces more verbose JSON-output with multiple `virtual-size` keys which leads to incorrect generation of `metadata.json` file (all values of `virtual-size` are placed into file and it becomes non-valid JSON). This behavious was described in #1746 . Example of old JSON output: { "virtual-size": 34359738368, "filename": "vm-100-disk-0.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": 2941440, "format-specific": { "type": "qcow2", "data": { "compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false } }, "dirty-flag": false } Example of new JSON output: { "children": [ { "name": "file", "info": { "children": [ ], "virtual-size": 42956488704, "filename": "/var/lib/libvirt/images/proxmox_6.4.qcow2", "format": "file", "actual-size": 1305301504, "format-specific": { "type": "file", "data": { } }, "dirty-flag": false } } ], "virtual-size": 42949672960, "filename": "/var/lib/libvirt/images/proxmox_6.4.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": 1305301504, "format-specific": { "type": "qcow2", "data": { "compat": "1.1", "compression-type": "zlib", "lazy-refcounts": true, "refcount-bits": 16, "corrupt": false, "extended-l2": false } }, "dirty-flag": false } This change adds comatibility in a fast-fix-way: awk regex gets in account only `virtual-size` key on the first level of `qemu-img info` JSON-output. |
||
---|---|---|
.. | ||
create_box_with_two_disks.sh | ||
create_box.sh | ||
prepare_redhat_for_box.sh |