|
- #!/bin/bash
-
- . config || exit 0
- set -e
- set -x
-
- # Customize the outer ISO image
- perl -p -i -e \
- "s/DISKNAME.*/DISKNAME NilmDBuntu $VERSION by Jim Paris/" \
- ${ISO}/README.diskdefines
-
- # The .disk/info file is important -- it's used by ubiquity to extract
- # out the distro name in dialogs, and I think casper might use it too
- echo "NilmDBuntu $VERSION by Jim Paris" > ${ISO}/.disk/info
-
- # Include openssh server at install time. Can't include it in the
- # image, because then we'd share keys on all machines, I think.
- cp ${ISO}/preseed/xubuntu.seed ${ISO}/preseed/nilmdbuntu.seed
- cat >> ${ISO}/preseed/nilmdbuntu.seed <<EOF
- d-i pkgsel/include string openssh-server
- EOF
-
- # Rename Xubuntu to NilmDBuntu in boot scripts; also changes
- # preseed file to the custom one
- perl -p -i \
- -e "s/Xubuntu/NilmDBuntu/g;" \
- -e "s/xubuntu/nilmdbuntu/g;" \
- ${ISO}/isolinux/txt.cfg ${ISO}/boot/grub/{grub,loopback}.cfg
-
- # Remove quiet and splash from boot command lines. Easier than a
- # custom plymouth theme and it's helpful.
- perl -p -i -e "s/ quiet splash//g;" \
- ${ISO}/isolinux/txt.cfg ${ISO}/boot/grub/{grub,loopback}.cfg
-
- # Run the customize-inner.sh script inside the chroot
- sudo cp customize-inner.sh ${FS}/root/customize-inner.sh
- sudo chmod +x ${FS}/root/customize-inner.sh
- ./enter.sh "cd /root ; ./customize-inner.sh"
|