diff --git a/docker.sh b/docker.sh deleted file mode 100755 index 3874493..0000000 --- a/docker.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash - -apt-get update -apt-get install -y xorriso genisoimage - -cd /root/unattended -ISONAME=$(ls | grep "netinst.iso" | sort | tail -n1 | sed 's/netinst/unattended/') -genisoimage -r -J -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -o ${ISONAME} isofiles -chown 1000:1000 ${ISONAME} diff --git a/unattended.sh b/unattended.sh index 072cc99..d41c980 100755 --- a/unattended.sh +++ b/unattended.sh @@ -9,6 +9,7 @@ sed -i "s/ROOT_PASSWORD/${ROOT_PASSWORD}/" preseed.cfg # Get the file name ISONAME=$(ls | grep "netinst.iso" | sort | tail -n1) +UNAME=$(echo ${ISONAME} | sed 's/netinst/unattended/') # Remove an already existing unattended iso of this same version, if existing rm -f $(echo ${ISONAME} | sed 's/netinst/unattended/') # Extract iso files @@ -36,6 +37,6 @@ cd .. # Repackage all the iso files chmod a+w isofiles/isolinux/isolinux.bin -docker run --interactive --tty --rm --volume $(pwd):/root/unattended debian:buster /root/unattended/docker.sh +genisoimage -r -J -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -o ${UNAME} isofiles # Remove the extracted (temporary) files and the preseed with the plaintext password sudo rm -rf isofiles preseed.cfg