/usr/share/auto-upgrade-tester/scripts/jeos-create-base-image is in auto-upgrade-tester 1:0.166.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #!/bin/sh
set -e
DIST=$(lsb_release -c -s)
if [ -z "$1" ]; then
echo "need distro codename to create as first argument "
exit 1
fi
# check depends
if [ ! -f /usr/bin/ubuntu-vm-builder ]; then
apt-get install -y ubuntu-vm-builder
fi
if [ ! -f /usr/bin/kvm ]; then
apt-get install -y kvm
fi
# create a default ssh key
if [ ! -e ssh-key ]; then
ssh-keygen -N '' -f ssh-key
fi
KERNEL=generic
if [ "$1" = "dapper" ]; then
KERNEL=386
fi
# create the image
ubuntu-vm-builder kvm $1 --kernel-flavour $KERNEL --ssh-key $(pwd)/ssh-key.pub \
--components main,restricted --rootsize 80000 --arch i386 --dest ubuntu-$1
# move into place
mv ubuntu-$1/*.qcow2 $1-i386.qcow2
|