Disables iCloud & Diags pop-up on first login 10.7-10.10

bwiessner
Contributor II

I found this Gem -

https://derflounder.wordpress.com/2014/10/16/disabling-the-icloud-and-diagnostics-pop-up-windows-in-yosemite/

https://github.com/rtrouton/rtrouton_scripts/tree/master/rtrouton_scripts/disable_apple_icloud_and_diagnostic_pop_ups

14 REPLIES 14

RobertHammen
Valued Contributor II

Yep, many of us are well aware of @rtrouton's status as a Mac deity ;-)

cwaldrip
Valued Contributor

I've almost set my default home page to Der Flounder. :-)

ckgov
New Contributor II

Anyone know how to get it into a working Apple Profile (.mobileconfig) ?

bentoms
Release Candidate Programs Tester

@ckgov As the values change when updating the OS, you might be better running the script at startup to stop the prompts.

Or not bother if people can signin with their iCloud account post logging in.

tcandela
Valued Contributor II

What part of the script disables the diagnostic popup? Only Yosemite has diagnostic popup. I never seen diag popup for Mavericks, just iCloud.

I used the following https://github.com/rtrouton/rtrouton_scripts/tree/master/rtrouton_scripts/first_boot

And used only the disable iCloud and diag popup section fom each respective script (10.9 and 10.10). Looks like the first boot script for 10.10 mentions anything about diagnostic popup.

MichaelC
New Contributor III

We have a bit of a fringe case, using PBIS Open for AD authentication against multiple domains, where only one domain doesn’t require a domain prefix. The script worked great for that one domain and any local accounts, but broke for accounts from any other prefixed domain. I fixed it by using numeric UIDs read from the home directories, instead of the names of the home directories themselves. It’s a two-line change, so that:

USER_UID=`basename “${USER_HOME}”`
if [ ! “${USER_UID}” = “Shared” ]

becomes:

if [ ! “${USER_HOME}” = “/Users/Shared” ]; then
USER_UID=`stat -r ${USER_HOME} | awk ‘{print $5}’`

The ‘chown’ command is quite happy using the numeric UID, and it works across all domains.

Incidentally, I run the script with our periodic softwareupdate check policy, and also as part of an experimental policy for upgrading 10.9 -> 10.10.

Kyuubi
Contributor

I've run the script from rtrouton's github. What I've seen is that it does suppress the iCloud setup but I still get the diagnostics pop up. Anybody else seeing this? Any ideas on how to get the diagnostics page to disappear as well?

rtrouton
Release Candidate Programs Tester

Kyuubi
Contributor

Thanks @rtrouton . You ARE the man.

Nix4Life
Valued Contributor

@ckgov if you haven't already, you may want to check this out from Amsys (@davidacland):
http://www.amsys.co.uk/2015/02/creating-config-profiles-instead-first-boot-script/
I used it for a few things and i will be working on this next week

donmontalvo
Esteemed Contributor III

@rtrouton did this break with El Capitan? Please let me know where to scp the ether-beer (etc.). :)

Don

--
https://donmontalvo.com

Aziz
Valued Contributor

@donmontalvo It definitely changed in 10.11.x. I can post the updated startup script I use in the morning, unless someone beats me to it!

RLR
Valued Contributor

I found that this script works for 10.11.x . Currently tested on one machine during the pre-stage imaging phase- can't remember where I found it or I would reference the source.

#!/bin/sh

# Determine OS version
osvers=$(sw_vers -productVersion | awk -F. '{print $2}')
sw_vers=$(sw_vers -productVersion)

# Checks first to see if the Mac is running 10.7.0 or higher. 
# If so, the script checks the system default user template
# for the presence of the Library/Preferences directory.
#
# If the directory is not found, it is created and then the
# iCloud pop-up settings are set to be disabled.

if [[ ${osvers} -ge 7 ]]; then

 for USER_TEMPLATE in "/System/Library/User Template"/*
  do
    defaults write "${USER_TEMPLATE}"/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool TRUE
    defaults write "${USER_TEMPLATE}"/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
    defaults write "${USER_TEMPLATE}"/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion "${sw_vers}"
  done

 # Checks first to see if the Mac is running 10.7.0 or higher.
 # If so, the script checks the existing user folders in /Users
 # for the presence of the Library/Preferences directory.
 #
 # If the directory is not found, it is created and then the
 # iCloud pop-up settings are set to be disabled.

 for USER_HOME in /Users/*
  do
    USER_UID=`basename "${USER_HOME}"`
    if [ ! "${USER_UID}" = "Shared" ] 
    then 
      if [ ! -d "${USER_HOME}"/Library/Preferences ]
      then
        mkdir -p "${USER_HOME}"/Library/Preferences
        chown "${USER_UID}" "${USER_HOME}"/Library
        chown "${USER_UID}" "${USER_HOME}"/Library/Preferences
      fi
      if [ -d "${USER_HOME}"/Library/Preferences ]
      then
        defaults write "${USER_HOME}"/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool TRUE
        defaults write "${USER_HOME}"/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
        defaults write "${USER_HOME}"/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion "${sw_vers}"
        chown "${USER_UID}" "${USER_HOME}"/Library/Preferences/com.apple.SetupAssistant.plist
      fi
    fi
  done
fi

Aziz
Valued Contributor

@donmontalvo

This is what I use as a "At Reboot" script during imaging.

#Disable iCloud Prompts
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion -string 10.11.1
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool YES
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant LastSeenBuddyBuildVersion 10.11.1
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant DidSeeSyncSetup -bool TRUE
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant DidSeeSyncSetup2 -bool TRUE
defaults write /System/Library/User Template/English.lproj/Library/Preferences/com.apple.SetupAssistant DidSeeiCloudSecuritySetup -bool TRUE
echo "iCloud disabled."