Conditions in ARM Templates to deploy specific resource block

Now ARM support condition property in resource so that we can use condition and if the condition is true then only that resource will get deployed.

Add condition property to a resource object, the resource object will only be deployed when the condition is met. The following sample code will show this:

Download simple ARM template and execute the same using New-AzureRmResourceGroupDeployment command.


below is example of powershell to deploy ARM template.

New-AzureRmResourceGroupDeployment -ResourceGroupName “omsworkspaceRG” -TemplateFile “C:\vedTech\OMSTemplate.json” -TemplateParameterFile “C:\vedTech\OMSParameters.json”



(Visited 1 times, 1 visits today)
, , , , , , ,

By Arun Sabale

Arun is a Solution Architect on enterprise client management with more than 14 years of experience in IT. Arun Sabale is Blogger and tech enthusiast. His main focus is on Azure cloud infra, Cloud automation with powershell, python, ARM terraform and all cloud infra services like compute, storage, network, automation, function api etc... LinkedIN -

Comments are closed.