/build/static/layout/Breadcrumb_cap_w.png

Whats the best way to deploy a package to a Mac and force a reboot?

What is the best way  install a .pkg on a Mac and force a reboot when complete? I want to ensure users have the ability to snooze the install which will reboot the system.

0 Comments   [ + ] Show comments

Answers (1)

Answer Summary:
Posted by: chucksteel 9 years ago
Red Belt
0
Create a install.sh script that will run the install and then the reboot command. It will look like this:

installer -pkg package.pkg -target /
shutdown -r now

Make sure the script is set as executable using the chmod command. Place the script in the same folder as the pkg and compress both of them into an archive. Upload this archive to the software title. When you create the distribution use the custom command option and enter the following:

unzip -o archive.zip && install.sh

I use this technique for complicated installs regularly although I don't force a reboot.


 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ