Ask Learn Preview
Please sign in to use this experience.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
The Intune management extension lets you upload PowerShell scripts in Intune to run on Windows devices, in addition to shell scripts for the macOS. The management extension supplements mobile device management (MDM) capabilities and makes it easier for you to move to modern management.
You can create scripts to run on the devices that provide the capabilities you need. For example, you can create a PowerShell script that installs a legacy Win32 app on your Windows devices, upload the script to Intune, assign the script to a Microsoft Entra group, and run the script on Windows devices. You can then monitor the run status of the script on Windows devices from start to finish.
The Intune management extension has the following prerequisites:
Windows | macOS |
---|---|
Version 1607 or later. | version 10.12 or later |
Devices must be joined to Microsoft Entra ID, including Hybrid AD joined devices. | Devices are managed by Intune. |
Automatic MDM enrollment must be enabled in Microsoft Entra ID. | Shell scripts begin with #! and must be in a valid location such as #!/bin/sh or #!/usr/bin/env zsh. |
Command-line interpreters for the applicable shells are installed. |
In the Microsoft Intune admin center, select Devices.
In the Policy section, select Scripts and select Add, then select Windows 10 and later.
Adding scripts is similar to the process for creating a profile. After adding a name and description, you'll configure the Script settings.
In Script settings, enter the following properties:
Select Next and configure scope tags and assignments. Note that PowerShell scripts in Intune can be targeted to Microsoft Entra device security groups or Microsoft Entra user security groups.
Adding a script for the macOS uses the same steps creating a PowerShell script policy, selecting macOS after choosing Add. The macOS script settings are slightly different.
In Script settings, enter the following properties:
Select Next and configure scope tags and assignments. Note that shell scripts assigned to user groups apply to any user signing in to the Mac.
Having an issue? We can help!
Please sign in to use this experience.
Sign in