Posted on 11-07-2022 03:44 PM
Hello everyone, I'm new to this community so please bare with me if this has been asked before. I'd like to deploy a script that can check what chip is installed on my Mac mini fleet and if needed, install it. Thanks in advance.
Posted on 11-07-2022 10:09 PM
1. If you are deploying via Jamf, you can create a smart group with Architecture Type criteria as arm64 and create a policy with File and Process payload to execute command "softwareupdate --install-rosetta --agree-to-license".
2. You can replace the command inpolicy as below to check the processor arch and install rosetta only for apple silicon devices..
[ $( /usr/bin/arch ) = "arm64" ] && /usr/sbin/softwareupdate --install-rosetta --agree-to-license
Hope this helps.
Thanks.
Posted on 11-08-2022 04:42 AM
@karthikeyan_mac I'll give this a try. I plan on setting up my lab today so I'll keep you posted. Thank you.
Posted on 11-08-2022 07:33 AM
@TJimenez Also here's the script, I place it in our App Store, but I like @karthikeyan_mac idea better. :-)
#!/bin/bash
arch=$(/usr/bin/arch)
if [ "$arch" == "arm64" ]; then
echo "Apple Silicon - Installing Rosetta"
/usr/sbin/softwareupdate --install-rosetta --agree-to-license
elif [ "$arch" == "i386" ]; then
echo "Intel - Skipping Rosetta"
else
echo "Unknown Architecture"
fi