How to Use SCCM Applications with AutoInstall

Introduction

SCCM is a powerful tool that allows you to install operating systems and applications based on your company’s needs. During Operating System Deployment (OSD) you want the device to install everything the user needs based on their department or role.

An useful tool in this scenario is to utilize SCCM’s ability to install applications based on variables.
In this post, I will show you how to find SCCM applications with autoinstall enabled in your environment.

I will also show you how to enable this option in the console and how to use them with computer variables.

It is also possible to create application variables during OSD but in this scenario I will only show it using computer variables.

Instructions

Enable AutoInstall on an Application

The first step is to allow a Task Sequence to install applications dynamically. You do this from inside the SCCM console.

Browse to your applications and open Properties. On the General Information page, make sure you check the checkbox with the label Allow this application to be installed from the Install Application task sequence action without being deployed.

Application properties where autoinstall is enabled

That’s all you need to do to prepare your applications. Note that you need to do this for all applications you want to use in the task sequence.

Finding the Applications with AutoInstall enabled

So, how do you know which applications already support autoinstall? Easy! Powershell is the best way to get an overview of all enabled applications.

When you enable the option to deploy during task sequence, SCCM updates a string in the application information. This string is SDMPackageXML and you can see this using powershell.

Connect PowerShell to SCCM

The first step is to launch powershell and connect to the SCCM site. The easiest way to do this is through the SCCM console.

You only need to press the blue button in the top left corner and select Connect via Windows PowerShell. I recommend using ISE so you can use the cmdlet in the next step.

Image showing how to connect powershell to SCCM from the console

Remember to run the script that opens to connect.

Find the SCCM Applications with AutoInstall

We are looking for applications where a value called AutoInstall is set to True, and we can find this using the following one-liner.

Get-CMApplication | Where-Object {$_.SDMPackageXML -like "*<AutoInstall>true</AutoInstall>*"} | select LocalizedDisplayName

The output contains the name of all applications that we can use during task sequence.

Powershell output with autoinstall applications

How to Use Computer Variables to Install Applications

This section of the blog post contains information about how you use the applications in the task sequence.

Prepare the Task Sequence

First off, you need to add an action to your task sequence that will check for applications to install.

In my case, it’s called OSDApps. The task sequence will look at the computer object in the database and look for variables starting with OSDApps.

Install Application with base variable name example

I also recommend checking the last two options. This allows the action step to continue installation of applications, even if one should fail. The last checkbox will remove the content from the cache when the installation is complete, which is nice when you deliver the device to a user.

Prepare the Computer Object

The Install Application action looks at the computer object for any variable that matches the Base variable name specified in the task sequence, followed by a two-digit number, starting with 01.

In the example below, I use OSDApps01 to install Adobe Acrobat XI.

SCCM computer object application variables

If you want to install multiple applications, then you need to add them to the computer object but increment the number by 1, e.g. the next application will be called OSDApps02, and so on.

Summary

Using variables to install applications is great, but as you might have noticed, a little troublesome to do manually.

This method works, but I suggest you use a solution that creates the variables during machine import to use it in an enterprise environment.

References

https://docs.microsoft.com/en-us/configmgr/osd/understand/task-sequence-steps#install-applications-according-to-dynamic-variable-list

Related posts

How to Enable BitLocker on Existing Devices Using SCCM

Configuring Local Administrator Password Solution (LAPS)

Leave a Reply

Your email address will not be published. Required fields are marked *