2014-06-11 12:07:29 +00:00
|
|
|
diff --git a/bin/make-base-vm b/bin/make-base-vm
|
2014-06-11 12:48:00 +00:00
|
|
|
index c1920f3..a5935fb 100755
|
2014-06-11 12:07:29 +00:00
|
|
|
--- a/bin/make-base-vm
|
|
|
|
+++ b/bin/make-base-vm
|
|
|
|
@@ -106,19 +106,6 @@ fi
|
|
|
|
|
|
|
|
libexec/config-bootstrap-fixup
|
|
|
|
rm -rf $OUT
|
|
|
|
-sudo vmbuilder kvm ubuntu --rootsize 10240 --arch=$ARCH --suite=$SUITE --addpkg=$addpkg --removepkg=$removepkg --ssh-key=var/id_dsa.pub --ssh-user-key=var/id_dsa.pub --mirror=$MIRROR --security-mirror=$SECURITY_MIRROR --dest=$OUT --flavour=$FLAVOUR --firstboot=`pwd`/target-bin/bootstrap-fixup
|
2014-06-11 12:48:00 +00:00
|
|
|
+env -i LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 sudo vmbuilder kvm ubuntu --rootsize 10240 --arch=$ARCH --suite=$SUITE --addpkg=$addpkg --removepkg=$removepkg --ssh-key=var/id_dsa.pub --ssh-user-key=var/id_dsa.pub --mirror=$MIRROR --security-mirror=$SECURITY_MIRROR --dest=$OUT --flavour=$FLAVOUR --firstboot=`pwd`/target-bin/bootstrap-fixup
|
2014-06-11 12:07:29 +00:00
|
|
|
mv $OUT/*.qcow2 $OUT.qcow2
|
|
|
|
rm -rf $OUT
|
|
|
|
-
|
|
|
|
-if [ $LXC = "1" ]; then
|
|
|
|
- #sudo debootstrap --include=$addpkg --arch=$ARCH $SUITE $OUT-root $MIRROR
|
|
|
|
- echo Extracting partition for lxc
|
|
|
|
- qemu-img convert $OUT.qcow2 $OUT.raw
|
|
|
|
- loop=`sudo kpartx -av $OUT.raw|sed -n '/loop.p1/{s/.*loop\(.\)p1.*/\1/;p}'`
|
|
|
|
- sudo cp --sparse=always /dev/mapper/loop${loop}p1 $OUT
|
|
|
|
- sudo chown $USER $OUT
|
|
|
|
- sudo kpartx -d /dev/loop$loop
|
|
|
|
- rm -f $OUT.raw
|
|
|
|
- # bootstrap-fixup is done in libexec/make-clean-vm
|
|
|
|
-fi
|
|
|
|
-
|