[tbb-commits] [gitian-builder/tor-browser-builder-3] Copy target image as a sparse file in LXC mode

gk at torproject.org gk at torproject.org
Fri Nov 7 11:08:13 UTC 2014


commit ef50217b3aaaf268fcfe907e85c884fe3932474b
Author: Lunar <lunar at torproject.org>
Date:   Mon Oct 13 00:26:22 2014 +0200

    Copy target image as a sparse file in LXC mode
    
    This will save us from writing a lot of zeros on disk.
---
 libexec/make-clean-vm |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libexec/make-clean-vm b/libexec/make-clean-vm
index 9915df3..b02b0d2 100755
--- a/libexec/make-clean-vm
+++ b/libexec/make-clean-vm
@@ -59,7 +59,7 @@ case $VMSW in
     qemu-img create -f qcow2 -o backing_file="$BASE.qcow2" "$OUT.qcow2"
     ;;
   LXC)
-    cp -a $BASE $OUT
+    cp -a --sparse=always $BASE $OUT
     on-target -u root /root/firstboot.sh
     ;;
   VBOX)





More information about the tbb-commits mailing list