This gist details how to generate a bootable High Sierra installer ISO image. It solves a few differences from the Sierra install. It assumes the Install downloaded into the directory with the script.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
src=./Install\ macOS\ High\ Sierra.app | |
hdiutil attach \ | |
./Install\ macOS\ High\ Sierra.app/Contents/SharedSupport/InstallESD.dmg \ | |
-noverify -nobrowse -mountpoint /Volumes/install_app | |
hdiutil create -o /tmp/HighSierra.cdr -size 7316m -layout SPUD -fs HFS+J | |
hdiutil attach /tmp/HighSierra.cdr.dmg -noverify -nobrowse -mountpoint \ | |
/Volumes/install_build | |
# Do something and rename the install_build mount point to "OS X Base System" | |
asr restore --source "${src}"/Contents/SharedSupport/BaseSystem.dmg \ | |
--target /Volumes/install_build --noprompt --noverify --erase | |
# High Sierra uses this link to mount the Packages dir in a ramdisk | |
cp -rp /Volumes/install_app/Packages /Volumes/OS\ X\ Base\ System/System/Installation/PackagesLink | |
cp -rp "${src}"/Contents/SharedSupport/BaseSystem.chunklist /Volumes/OS\ X\ Base\ System/BaseSystem.chunklist | |
cp -rp "${src}"/Contents/SharedSupport/BaseSystem.dmg /Volumes/OS\ X\ Base\ System/BaseSystem.dmg | |
hdiutil detach /Volumes/install_app | |
hdiutil detach /Volumes/OS\ X\ Base\ System/ | |
hdiutil convert /tmp/HighSierra.cdr.dmg -format UDTO -o /tmp/HighSierra.iso | |
mv /tmp/HighSierra.iso.cdr ./HighSierra.iso | |
rm -f /tmp/HighSierra.cdr.dmg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment