mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
Retrieve disk format and virtual size directly (#1274)
When uploading disks to libvirt storage it is unnecessary to require that the virtual size or the format be provided as these can be retrieved by calling qemu-img on the box files to retrieve the required information. Update the handle box image support to separate the handling of the two different formats and remove the need to specify the additional settings in the case of the V2 format for multi disk boxes.
This commit is contained in:
@@ -17,15 +17,12 @@ then
|
||||
cat > "${NEW_PATH}/${BOX_VERSION}/libvirt/metadata.json" <<EOF
|
||||
{
|
||||
"provider": "libvirt",
|
||||
"format": "qcow2",
|
||||
"disks" : [
|
||||
{
|
||||
"virtual_size": 2
|
||||
},
|
||||
{
|
||||
{
|
||||
},
|
||||
{
|
||||
"path":"disk2.qcow2",
|
||||
"virtual_size":10
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
EOF
|
||||
|
||||
Reference in New Issue
Block a user