How to use Conditionals in Ivanti EPM Provisioning

Version 15

    Verified Product Versions

    Endpoint Manager 2016.xEndpoint Manager 2017.xEndpoint Manager 2018.x


    This document is intended to cover the newly added feature of Conditionals in LANDESK Provisioning. Conditionals are best used to consolidate templates, allowing flexibility for:

    • Multiple Images
    • Software Distribution
    • Disk Configuration
    • Hardware Types
    • BIOS Architecture


    What to Expect from Conditionals


    • Conditionals in LANDESK provisioning use "If and Else" arguments to determine multiple outcomes for a template.
    • Stacking of multiple "if" conditionals is allowed. LANDESK will address all "if" conditionals one at a time.
    • "Else" conditionals will only apply to the "if" conditional directly preceding it.
    • Conditionals can be used at any point in the provisioning template, in any section.
    • Custom scripts can be used in conjunction with Conditionals.
      • A successful script (return 0) will result in an "if" conditional being executed.
      • A non-successful script (not return 0) will result in LANDESK skipping past the associated conditional, or moving on to a corresponding "else" conditional.


    Adding Conditionals to a Template


    In this case, a default Deploy Template will be customized using Conditionals. To create such a template, browse to Tools > Provisioning. In the Operating System Provisioning tool, click New Template > Deploy Template.


    Fill out the required fields and click Create. Should look something like this:

    Default Deploy.png

    Right Click any of the actions, and select Add Condition > If or Else

    Add Condition.png


    Utilizing Conditionals in conjunction with Public Variables


    In LANDESK 2016, a new action type was introduced called Compare Variable. This action is extremely useful when using conditionals in provisioning. The following is an example of where to use this new feature:


    We have an Image for Laptops and an Image for Desktops. How do we utilize both images in one Template?


    This scenario will use the same template created above. The first step in using conditionals is to find a characteristic that LANDESK can use to differentiate between devices. LANDESK Inventory yields a different value for Desktops and Laptops.


    For this example, we have "Chassis Type" recorded as NoteBook and Mini Tower. These values can be used as conditional arguments using Public Variables.


    To add "Chassis Type" to public variables, open the Operating System Provisioning tool and select the Tools drop-down list from the toolbar. Then select Public Variables.

    Public Variables.png

    Select Add. Enter any Search Value that seems fitting - needs to be one word. The Type will be set to "Database value." The replacement value will be set to the entry in inventory; "Computer"."System"."Chassis Type"

    User-Defined Variable.png

    Select OK.


    Open the properties of the base template created above and right click the OS installation section from the Action List. Select Add Condition > If.


    Right click the newly created condition and select Add Action. Select Compare Variable in the "Type" drop-down list. Select the variable created above in the "Variable" drop-down list and enter Mini Tower in the blank space. Click Apply.

    Chassis Type.png

    Right Click OS installation once more and select Add Action. Select Deploy Image from the drop-down list, name the action appropriately, and click OK. Fill out the action properties to deploy the desktop image.


    Now do the same with the Notebook image, only this time use an Else conditional. It should look something like this:

    Template Complete.png


    Note: Using public variables that call to this inventory value will likely only be accurate if the device already existed in LANDESK inventory.