Menu

1 / 2

Set up Jamf scripts safely: check them before they touch a Mac

DEV Community: github·Christian Anderson·4 days ago
#D95UohQO
#devtogithub#technology#devto#dev#scripts
Reading 0:00
15s threshold

JSS-Scripts is my fork of Balmes Pavlov's Jamf Pro scripts : deferrable macOS updates, upgrade nags, TCC resets, printer resets. Almost all of it is his work, and his repo has newer versions. Check there first.

I've added a setup guide anyway, because the process matters more than the scripts: nothing like this should reach a fleet without passing one test Mac first.

Check they parse, with the right shell

The README used to say " bash -n passes for every script". True, and a bit misleading: three of them are zsh. The check now reads each script's first line and uses that shell, and validates the LaunchDaemon as a real plist. It runs every week on a fresh Ubuntu machine.

It turned up two things worth knowing:

OS_Upgrade.sh gets a here-document warning from bash 5 at line 786.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.