summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2008-04-17 12:13:49 +0200
committerDaniel Baumann <daniel@debian.org>2011-03-09 19:03:32 +0100
commit5d970f543638ba6218426e0a94f11e9a78d97c2c (patch)
tree6dcb471cc50b5351351fc9ff018c98a12cb55853
parent002c79ef51cc56b933e762de7af9ef8733b13707 (diff)
downloadvyos-live-build-5d970f543638ba6218426e0a94f11e9a78d97c2c.tar.gz
vyos-live-build-5d970f543638ba6218426e0a94f11e9a78d97c2c.zip
Adding example script to build a row of images.
-rwxr-xr-xexamples/cron/build.sh51
1 files changed, 51 insertions, 0 deletions
diff --git a/examples/cron/build.sh b/examples/cron/build.sh
new file mode 100755
index 000000000..0855a06a4
--- /dev/null
+++ b/examples/cron/build.sh
@@ -0,0 +1,51 @@
+#!/bin/sh -x
+
+set -e
+
+DATE="$(date +%Y%m%d)"
+
+for DISTRIBUTION in etch lenny sid
+do
+ rm -rf cache/stages*
+
+ for FLAVOUR in standard gnome-desktop kde-desktop xfce-desktop
+ do
+ mkdir -p config
+
+ if [ -e .stage ]
+ then
+ lh clean
+ fi
+
+ rm -rf config
+ rm -rf cache/packages*
+ rm -rf cache/stages_rootfs
+
+ lh config -d ${DISTRIBUTION} -p ${FLAVOUR} --cache-stages "bootstrap rootfs" --source enabled --mirror-bootstrap http://mirror/ftp.debian.org/debian/ --mirror-chroot http://mirror/ftp.debian.org/debian/ --mirror-chroot-security http://mirror/ftp.debian.org/debian-security/
+
+ if [ "${DISTRIBUTION}" = "sid" ]
+ then
+ echo 'deb http://live.debian.net/debian-snapshots/ ./' > config/chroot_sources/live-snapshots.chroot
+ echo 'deb http://live.debian.net/debian-snapshots/ ./' > config/chroot_sources/live-snapshots.boot
+
+ wget http://ftp-master.debian-unofficial.org/other/openpgp/archive-key-2008.asc -O config/chroot_sources/live-snapshots.chroot.gpg
+ wget http://ftp-master.debian-unofficial.org/other/openpgp/archive-key-2008.asc -O config/chroot_sources/live-snapshots.binary.gpg
+
+ fi
+
+ lh build | tee debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.iso.log
+
+ mv binary.iso debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.iso
+ mv source.tar.gz debian-live-${DISTRIBUTION}-source-${FLAVOUR}.tar.gz
+ mv binary.packages debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.iso.packages
+ mv binary.list debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.iso.list
+
+ lh clean --binary
+ lh config -b usb-hdd
+ lh binary | tee debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.img.log
+
+ mv binary.img debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.img
+ mv binary.packages debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.img.packages
+ mv binary.list debian-live-${DISTRIBUTION}-i386-${FLAVOUR}.img.list
+ done
+done