You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: Determine what changes will happen to your resources before deploying an Azure Resource Manager template.
4
4
author: mumian
5
5
ms.topic: conceptual
6
-
ms.date: 04/28/2020
6
+
ms.date: 04/29/2020
7
7
ms.author: jgao
8
8
---
9
9
# ARM template deployment what-if operation (Preview)
@@ -100,7 +100,7 @@ To preview changes before deploying a template, add the `-Whatif` switch paramet
100
100
*`New-AzResourceGroupDeployment -Whatif` for resource group deployments
101
101
*`New-AzSubscriptionDeployment -Whatif` and `New-AzDeployment -Whatif` for subscription level deployments
102
102
103
-
Or, you can use the `-Confirm` switch parameter to preview the changes and get prompted to continue with the deployment.
103
+
You can use the `-Confirm` switch parameter to preview the changes and get prompted to continue with the deployment.
104
104
105
105
*`New-AzResourceGroupDeployment -Confirm` for resource group deployments
106
106
*`New-AzSubscriptionDeployment -Confirm` and `New-AzDeployment -Confirm` for subscription level deployments
@@ -117,10 +117,10 @@ To preview changes before deploying a template, use `what-if` with the deploymen
117
117
*`az deployment group what-if` for resource group deployments
118
118
*`az deployment sub what-if` for subscription level deployments
119
119
120
-
Or, you can use the `--confirm-with-what-if`parameter to preview the changes and get prompted to continue with the deployment.
120
+
You can use the `--confirm-with-what-if`switch (or its short form `-c`) to preview the changes and get prompted to continue with the deployment.
121
121
122
-
*`az deployment group create --confirm-with-what-if` for resource group deployments
123
-
*`az deployment sub create --confirm-with-what-if` for subscription level deployments
122
+
*`az deployment group create --confirm-with-what-if`or `-c`for resource group deployments
123
+
*`az deployment sub create --confirm-with-what-if`or `-c`for subscription level deployments
124
124
125
125
The preceding commands return a text summary that you can manually inspect. To get a JSON object that you can programmatically inspect for changes, use:
The what-if operation supports using [deployment mode](deployment-modes.md). When set to complete mode, resources not in the template are deleted. The following example deploys a [template that has no resources defined](https://github.com/Azure/azure-docs-json-samples/blob/master/empty-template/azuredeploy.json) in complete mode.
336
336
337
-
To preview changes before deploying a template, use the `-Confirm` switch parameter with the deployment command. If the changes are as you expected, confirm that you want the deployment to complete.
337
+
To preview changes before deploying a template, use the confirm switch parameter with the deployment command. If the changes are as you expected, acknowledge that you want the deployment to complete.
0 commit comments