Images can have a post script associated with them. It will run after the image has successfully applied. The script receives 1 argument, a path to the mounted boot volume of the imaged disk.
There is an option to require the post script to succeed (return 0). Otherwise the image will report as a failure and stderr from the post script will be displayed.
Refactored beginImaging, removing a lot of the nested logic.
beginImaging
, removing a lot of the nested logic.