Generate the isofile with genisoimage

This commit is contained in:
Jeremy Gardais 2018-12-26 14:55:32 +01:00
parent 04542158ec
commit 21c65cf32b
1 changed files with 8 additions and 1 deletions

View File

@ -16,6 +16,7 @@ DEBIAN_ISO_MINI_URL="http://ftp.nl.debian.org/debian/dists/${DEBIAN_VERSION_NAME
TEMP_DIR_ISO=$(mktemp -d -t debian-iso-XXXXXX.tmp) TEMP_DIR_ISO=$(mktemp -d -t debian-iso-XXXXXX.tmp)
DEBIAN_DL_ISO_PATH="${TEMP_DIR_ISO}/debian.iso" DEBIAN_DL_ISO_PATH="${TEMP_DIR_ISO}/debian.iso"
DEBIAN_PRESEED_ISO_PATH="$(dirname ${TEMP_DIR_ISO})/preseed-debian-${DEBIAN_VERSION_NB}-amd64.iso"
# }}} # }}}
@ -32,6 +33,10 @@ if [ ! $(command -v gzip) ]; then
printf '%b\n' "ERROR: Please install 'gzip' bin:\\nsudo apt install gzip" printf '%b\n' "ERROR: Please install 'gzip' bin:\\nsudo apt install gzip"
exit 1 exit 1
fi fi
if [ ! $(command -v genisoimage) ]; then
printf '%b\n' "ERROR: Please install 'genisoimage' bin:\\nsudo apt install genisoimage"
exit 1
fi
# }}} # }}}
# Test vars {{{ # Test vars {{{
@ -100,7 +105,9 @@ find . -follow -type f -not \( -name "md5sum.txt" -o -name 'mkisofs' -o -name 'B
cd - || exit 2 cd - || exit 2
# }}} # }}}
# Generate new bootable iso {{{ # Generate new bootable iso {{{
genisoimage -r -J -b isolinux/isolinux.bin -c isolinux/boot.cat \
-quiet -no-emul-boot -boot-load-size 4 -boot-info-table \
-o "${DEBIAN_PRESEED_ISO_PATH}" "${TEMP_DIR_ISO}"
# }}} # }}}
# If extract image # If extract image