Microsoft Skype (definitely) and Teams (maybe) – Disabling automatic updates

With version 8.x of Skype and since the debut of Teams, Microsoft have been using the Squirrel framework to manage automatic updates of these applications. This is undesirable in lab/managed environments where users typically aren’t local administrators, as they’re often presented with a dialog like this, which they can’t do much with, other than ask IT for help:

SquirrelUpdate

If we’re packaging and deploying these applications (which we normally would be in the environments we manage), then they’re usually owned by root and can’t be modified by standard user accounts. So, what is an admin to do?

It isn’t possible to disable this via managed preferences or a configuration profile as the Squirrel framework doesn’t provide a preference domain or preference for it. However, it turns out that it does have an environment variable we can set. Bear in mind that setting this knocks out automatic updates for all apps that use Squirrel (except those that Nerf that shit so hard).

All you need to do is run this command, as the current logged in user:

/bin/launchctl setenv DISABLE_UPDATE_CHECK 1

You’ll notice that upon restarting, the auto-updating-annoying-behavior will come back. To get this to stick, run the above command in a script at login with Outset or put it in a Launch Agent, like this one (copy to /Library/Launch Agents):

Thanks to the awesome Tim Sutton for uncovering this with the Slack application a while back (before they changed it) – check out his post and please support the issue he raised on Github:

https://macops.ca/disabling-squirrel-updates/

https://github.com/Squirrel/Squirrel.Mac/issues/192

Thanks also to Rick Heil for the idea of putting this into a Launch Agent.

You can tell if an application uses the Squirrel framework by ctrl+clicking it, choosing Show Package Contents, then looking inside:

SkypeSquirrel

Note that I have tested/verified that this works with Skype, which seems to check for and download updates on every launch. Teams seems to check for updates 15 minutes after launch, then every 45 minutes (or does it?), if you take a peek at line 54234 and beyond in /Applications/Microsoft Teams.app/Resources/app.asar:

// Check for updates 15 mins after app start and then every 45 mins
const INITIAL_CHECK = 15 * 60 * 1000;
const CHECK_FREQUENCY = 3 * 60 * 60 * 1000; // TODO (jhreddy) change the following from 3 hours to 45 mins.

With this environment variable set, I noticed that Teams did download the update in the background 15 minutes after launch, but did not prompt to install it. I confess that I didn’t bother to test if Teams prompted to update 15 minutes after launch without the environment variable set. It’s late and I ran out of patience. 😉 If you know better (or worse), please drop a comment.

And yep, I know the icon at the top of this post is a chipmunk and not a squirrel… 😀

Advertisements

Author: n.martin

Managing 450-odd Macs at a university, innit.

One thought on “Microsoft Skype (definitely) and Teams (maybe) – Disabling automatic updates”

  1. Thanks, this was very helpful! Was having the same problem and kept finding non-answers (“You can’t disable autoupdates of Skype, there are no preferences to do that anymore”).

    Liked by 1 person

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s