When you run a script, you can choose a priority for running the script. You can also enter parameter values for the script.
When running a script that contains HTML tags in the output, the tags are not rendered in policy logs.
To run a script on computers, the script must be stored on the distribution point you plan to deploy it from and in Jamf Pro, or in the Jamf Pro database.
- In Jamf Pro, click Computers in the sidebar.
- Click Policies in the sidebar.
- Click New.
- Use the General payload to configure basic settings for the policy, including the trigger and execution frequency.
- Select the Scripts payload and click Configure.
- Click Add for the script you want to run.
- Configure the settings for the script.
- Use the Restart Options payload to configure settings for restarting computers.
- Click the Scope tab and configure the scope of the policy.
- (Optional) Click the Self Service tab and make the policy available in Self Service.
- (Optional) Click the User Interaction tab and configure messaging and deferral options.
- Click Save .
The policy runs on computers in the scope the next time they check in with Jamf Pro and meet the criteria in the General payload.
Jamf Pro truncates the output of policy logs after they reach 25 KB in size. If your environment relies on scripts with detailed error messaging, you may want to modify them to minimize the outputs to simplify potential troubleshooting measures in the future.