Posted on 04-01-2016 11:51 AM
Hi All,
Looking for a way to sign our users out of the AppStore and iCloud as we plan on restricting those going forward.
Found a few discussions like This Post but it doesn't seem to be working on El Capitan. We've noticed the ~/Library/Preferences/com.apple.storeagent.plist file doesnt seem to exist anymore as well.
Has anyone had any success doing this?
Solved! Go to Solution.
Posted on 04-01-2016 12:51 PM
Just distribute the Mac App Store command line interface with Casper:
Then you can run the command
mas signout
Posted on 04-01-2016 12:51 PM
Just distribute the Mac App Store command line interface with Casper:
Then you can run the command
mas signout
Posted on 06-07-2023 12:05 PM
7 years later and this still works with brew.
I'm working on a simple bash script to be pulled from a local server, install brew with their command, apply the zprofile and shellenv variables/defaults (so "brew" commands can run), run the signout command, and be done. I may throw up a new post and share it once I get it working the way I want.
Thanks for this!!!!! This is major.
Posted on 04-01-2016 01:07 PM
@tobiaslinder What would be the best way for one to distribute this? Do a detailed composer snap and install from source?
Posted on 04-01-2016 01:18 PM
I'd never seen this tool before. Thanks for posting the link to it @tobiaslinder Looks useful, but I haven't yet figured out what I would use it for.
@Ricky No need to go through a whole snapshot for that. Go to the Releases page and download the compiled version. Place it where you want it to go on your Mac, like say in, /usr/local/bin/ and then open Composer. Drag the binary from /usr/local/bin/ into the Composer sidebar and it will create a new source with the binary only in it. Whole process takes about a minute, including downloading it!
Posted on 04-01-2016 01:27 PM
@mm2270 Wow that was a simple process! Thank you very much for the help. :)
Posted on 04-01-2016 01:33 PM
Yes @mm2270, it really is an awesome tool. You could basically update your appstore apps that you distributed without VPP by running a policy with the commands:
mas signin
mas upgrade
mas signout
Not the way apple would like us too do it but definitely also a way to get the job done on machines that are not personalized.
Posted on 04-01-2016 02:27 PM
@tobias2006 Can that command be put in a single script, which is then put in a policy? Will the script run as
1) mas signin
2) mas upgrade
waits to complete
3) mas signout
Posted on 04-04-2016 06:45 AM
Thanks @tobiaslinder .
I had never heard of this tool but it did the trick!
Posted on 12-12-2017 08:33 AM
Going to ask here before starting a new discussion. The mas signout works fine for me if i type it in manually but if I try to push a script out to do it it won't work. History says the script ran fine and exited but the user is still logged in. I've been testing it on a 10.12 machine. I attached a screen shot of my script. Any suggestion?
Posted on 02-28-2018 03:02 PM
@mcmeekin91 Have you ever figured out how to run mas via policy? I've tried using launchctl asuser [uid] /usr/local/bin/mas but doesn't work. I've also tried sudo -u [logged in user] /usr/local/bin/mas and that isn't working either.
Seems like it's trying to use mas under management account or root.
Posted on 02-25-2020 03:39 AM
Hi @ddasilva ,
Is this working for you. have you tested on Catalina.
Could you please help me to resolve this. The mas signout works fine for me if I type it in manually but if I try to push a script out to do it it won't work on catalina10.15.3.