Improve build_all.sh so that it actually works

Do not put use generic environment variables that are in conflict
with live-build internal variables. Auto-publish the resulting images.
debian-cd
root 13 years ago
parent d11fbed180
commit a1d50a4c32

2
.gitignore vendored

@ -1,5 +1,7 @@
binary.*
prepare.log
binary
images
cache
chroot
.stage

@ -3,4 +3,4 @@
lb clean noauto "$@"
rm -f config/binary config/bootstrap \
config/chroot config/common config/source
rm -f binary.log
rm -f binary.log prepare.log

@ -2,13 +2,24 @@
set -e
ARCHES="i386 amd64"
DATE=$(date +%Y%m%d)
for ARCH in ARCHES; do
lb clean --purge
lb config --architecture $ARCH
lb build
mv binary.iso kali-$ARCH.iso
KALI_ARCHES="i386 amd64"
KALI_VERSION="${VERSION:-daily}"
cd $(dirname $0)
for KALI_ARCH in $KALI_ARCHES; do
lb clean --purge >prepare.log 2>&1
lb config --architecture $KALI_ARCH >>prepare.log 2>&1
lb build >/dev/null
if [ ! -e binary.iso ]; then
echo "Build of $KALI_ARCH live image failed" >&2
echo "Last 50 lines of the log:" >&2
tail -n 50 binary.log >&2
exit 1
fi
mv binary.iso images/kali-$KALI_VERSION-$KALI_ARCH.iso
mv binary.log images/kali-$KALI_VERSION-$KALI_ARCH.log
done
sha1sum images/*.iso >>images/SHA1SUMS

Loading…
Cancel
Save