From ffa211619c9d00ddcdf09fee5005b1a917b3d27c Mon Sep 17 00:00:00 2001 From: Sven Vogel Date: Wed, 4 Dec 2019 10:59:17 +0100 Subject: [PATCH 1/4] remove unused chksum flag --- scripts/storage/secondary/createtmplt.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/storage/secondary/createtmplt.sh b/scripts/storage/secondary/createtmplt.sh index 4e8db4633f03..391b291d3bbd 100755 --- a/scripts/storage/secondary/createtmplt.sh +++ b/scripts/storage/secondary/createtmplt.sh @@ -210,7 +210,6 @@ echo "filename=$tmpltname" > /$tmpltfs/template.properties echo "description=$descr" >> /$tmpltfs/template.properties # we need to rethink this property as it might get changed after download due to decompression # option is to recalcutate it here -echo "checksum=$cksum" >> /$tmpltfs/template.properties echo "hvm=$hvm" >> /$tmpltfs/template.properties echo "size=$imgsize" >> /$tmpltfs/template.properties From 2e3a67132d22177cfab77831761d3193587d2a2e Mon Sep 17 00:00:00 2001 From: Sven Vogel Date: Wed, 4 Dec 2019 11:01:45 +0100 Subject: [PATCH 2/4] refactor cloud-install-sys-tmplt / add qemu-img command to calculate correct virtual size --- .../storage/secondary/cloud-install-sys-tmplt | 280 ++++++++---------- 1 file changed, 129 insertions(+), 151 deletions(-) diff --git a/scripts/storage/secondary/cloud-install-sys-tmplt b/scripts/storage/secondary/cloud-install-sys-tmplt index 91b3a7c9088f..b900f8f30223 100755 --- a/scripts/storage/secondary/cloud-install-sys-tmplt +++ b/scripts/storage/secondary/cloud-install-sys-tmplt @@ -1,5 +1,4 @@ #!/bin/bash -# $Id: installrtng.sh 11251 2010-07-23 23:40:44Z abhishek $ $HeadURL: svn://svn.lab.vmops.com/repos/vmdev/java/scripts/storage/secondary/installrtng.sh $ # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file @@ -20,15 +19,30 @@ usage() { - printf "Usage: %s: -m -f [-h ] [ -s ][-u ] [-F ] [-e