blob: abdd73008c5169f2148ec2f8cfda26db5566a4fd (
plain)
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
|
#!/bin/bash
# Ensure git\VBoxManage is installed
# Get vmdebootstrap code
# Run vmdebootstrap script to create image
# Convert image to vdi hard drive
# don't tolerate errors.
set -e
basedir=`pwd`
IMAGE=$1
# Get vmdebootstrap code
rm -rf vmdebootstrap
git clone git://gitorious.org/~nickdaly/vmdebootstrap/nickdalys-vmdebootstrap.git
# Run vmdebootstrap script to create image
sudo ./vmdebootstrap/vmdebootstrap --log freedombox.log --log-level debug --image $IMAGE.img --hostname freedombox \
--size 1G --verbose --enable-dhcp --package ssh --package apache2 --package git --package mercurial \
--package build-essential --package checkinstall --package python-simplejson \
--mirror http://ftp.uk.debian.org/debian/ --package pandoc --package python-cheetah \
--package python-argparse \
--customize=$basedir/freedombox-customize --root-password=password1 --arch=i386
# Convert image to vdi hard drive
VBoxManage convertdd $IMAGE.img $IMAGE.vdi
#mkdir testing
#sudo mount -o loop,offset=1048576 freedombox.img testing/
#sudo umount testing/
|