In earlier versions of ARM templates, there was no provision of using if...else conditional statements. During the Build 2018 event, new functions were released to ARM templates, and the conditions feature was one of those functions. There are times when a resource should be provisioned based on a condition. For example, a resource should be conditionally provisioned, based on a parameter value of true only.
ARM templates provide multiple comparison functions such as equals, greater, greaterOrEquals, less, and lessOrEquals that are self-explanatory and used in conjunction with the if logical function.
There are also other logical functions such as and, or , and not available in ARM templates, and they can be combined with comparison functions, to create dynamic conditional expressions.
Conditions can be authored in two ways in ARM templates:
- Conditions...