macOSUpgrade
macOSUpgrade copied to clipboard
Self Service won't quit when ran from self service
I have created this policy and it seems to run fine, but it doesn't seem to quit self-service.
I'm currently testing this on line 189
declare -a startosinstallOptions=(--agreetolicense --forcequitapps --nointeraction && sleep 10 && osascript -e 'tell application "Self Service" to quit')
I add this right before this command at the end of the script.
sudo killall 'Self Service'
Begin Upgrade
startosinstallCommand=""$OSInstaller/Contents/Resources/startosinstall" ${startosinstallOptions[*]} >> $osinstallLogfile 2>&1 &" /bin/echo "Running a command as '$startosinstallCommand'..." eval "$startosinstallCommand"
Again this all could just be a user error.
This is a duplicate issue #135. It is addressed #140. Could you share us condition of failure detail?
The new issue stems from the discovery that the --forcequitapps flag is no longer quitting Self Service when used with macOS 11 Big Sur installers. https://www.jamf.com/jamf-nation/discussions/37297/big-sur-upgrade-bash-command
Those that are running startosinstall directly have resorted to leveraging AppleScript to facilitate the quit command as a workaround.
I did test this on macOS High Sierra and same issue with Self Service not quitting.