Search

Håvard Siegel Haukeberg

Paste life: Ctrl+C -> Ctrl+V [MVP]

Tag

GPO

Deploy custom script with Microsoft Intune

Once you have:

  1. Created a script
  2. Packaged the script in an EXE

you should be ready to deploly that script to computers running the Microsoft Intune Management Agent. The Intune MDM channel does not support EXE, only MSI.

1
Log into Intune and go to Apps
2
Select Software Installer and select EXE then browse for the EXE

Follow the Wizard.

3
You are done. Now you need to move the user or PC into that group for deployment. Deploy to all PC’s? apply to all computers instead of a group.

7

8

 

 

3
Venter på å kjøre script
6
Manuelle oppgaver som kan gjøres på klienten

 

 

 

 

 

Advertisements

Create a GPO Script for Microsoft Intune

Microsoft Intune can not push out Group Policies onto computers, but we can target users or devices with scripts that change that setting in the registry.

Here is how you create a simple script that does just that.

@Echo off
echo A Script to set a Registry value using Windows Intune
REM registry key
reg add HKLM\Software\Policies\Microsoft\PassportForWork /f
reg add HKLM\Software\Policies\Microsoft\PassportForWork\ /v Enabled /t REG_DWORD /d 0 /f
if errorlevel 1 (
echo Error installing reg key
exit /b 1
) else (
echo Installed regkey
)
exit /b 0

 

Simply copy this script into a notepad file and then save it as PassportForWork.CMD right click and Run as Administrator to input the software policy where we set Passport for Work enabled as = 0 “Turn Off”

You can enter some of these register values:

REG_BINARY
REG_DWORD
REG_EXPAND_SZ
REG_LINK
REG_MULTI_SZ

Read more here: Registry Values (Technet)

 

Thanks to Richard Harrison at http://www.cableplugger.com/2013/03/adding-windows-registry-entry-with.html

Create a GPO Registry Key Script Package for Microsoft Intune

Here is how you create a script that adds a registry setting to the computers managed by Microsoft Intune.

Navigate to:

C:\Windows\System32\iexpress.exe

Right click it and select “Run as Administrator”

iexplore

12345678

9
Click Browse and select where you want the file to be saved

101112

success
You now have a EXE file that you can upload and deploy in Intune

Blog at WordPress.com.

Up ↑

%d bloggers like this: