mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
If the disk size is specified as a decimil number the generated metadat.json file is invalid resulting in a broken vagrant box. Wraped this in the awk int() function to only print the integer part of the disk size.
This commit is contained in:
parent
15d12d1053
commit
0aea938dea
@ -81,7 +81,8 @@ fi
|
|||||||
|
|
||||||
cd "$TMP_DIR"
|
cd "$TMP_DIR"
|
||||||
|
|
||||||
IMG_SIZE=$(qemu-img info "$TMP_IMG" | grep 'virtual size' | awk '{print $3;}' | tr -d 'G')
|
IMG_SIZE=$(qemu-img info "$TMP_IMG" | grep 'virtual size' | awk '{print int($3);}' | tr -d 'G')
|
||||||
|
echo "IMAGE SIZE ====> ${IMG_SIZE}"
|
||||||
|
|
||||||
cat > metadata.json <<EOF
|
cat > metadata.json <<EOF
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user