Home > Jamf Pro, Jamf Pro API, Scripting > Removing restart options from all Jamf Pro policies in a specified category

Removing restart options from all Jamf Pro policies in a specified category

As a follow-on to my previous post on removing the Restart Options section from Jamf Pro policies, I’ve written a script to target the policies in a particular Jamf Pro category. For more details, please see below the jump.

This script is designed to do the following:

  1. List all categories on a Jamf Pro server.
  2. Allow a category to be specified.
  3. List all policies (if any) associated with that category.
  4. Confirm that the restart options should be removed from all policies in that category.
  5. Remove the restart options from all policies in that category.

When the script is run, you should see output similar to that shown below.

You’ll be requested to enter the name of a category.

Screen Shot 2020 05 22 at 10 27 57 AM

 

You’ll be asked to confirm that you want to remove the restart options from the relevant policies.

Screen Shot 2020 05 22 at 10 29 35 AM

 

Once confirmed, the restart options will be removed.

Screen Shot 2020 05 22 at 10 31 06 AM

 

The script is available from following address on GitHub:

https://github.com/rtrouton/rtrouton_scripts/tree/master/rtrouton_scripts/Casper_Scripts/Jamf-Pro-Remove-Restart-Options-From-All-Policies-In-Specified-Category

  1. No comments yet.
  1. No trackbacks yet.

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

%d bloggers like this: