Blame chrooter/build-initial-system.sh

e71c94
#!/bin/bash -x
e71c94
e71c94
set -e
e71c94
e71c94
arch=i386
e71c94
suite=wheezy
e71c94
chroot_dir="/var/chroot/$suite"
e71c94
apt_mirror="ftp://ftp.debian.org/debian/"
e71c94
e71c94
export DEBIAN_FRONTEND=noninteractive
e71c94
debootstrap --arch $arch $suite $chroot_dir $apt_mirror
e71c94
e71c94
cat <<eof> $chroot_dir/etc/apt/sources.list</eof>
e71c94
deb $apt_mirror $suite main
e71c94
deb $apt_mirror $suite-updates main
e71c94
deb http://security.debian.org/ $suite/updates main
e71c94
EOF
e71c94
e71c94
chroot $chroot_dir apt-get update
e71c94
chroot $chroot_dir apt-get upgrade -y
e71c94
chroot $chroot_dir apt-get autoclean
e71c94
chroot $chroot_dir apt-get clean
e71c94
chroot $chroot_dir apt-get autoremove
e71c94
9a8dee
genisoimage -quiet -R -o "$olddir/debian-$suite-$arch.iso" "$chroot_dir"
a1747c
e71c94
rm -rf $chroot_dir