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
Copy file name to clipboardExpand all lines: articles/azure-resource-manager/templates/template-tutorial-export-template.md
+24-24Lines changed: 24 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,25 +2,25 @@
2
2
title: Tutorial - Export template from the Azure portal
3
3
description: Learn how to use an exported template to complete your template development.
4
4
author: mumian
5
-
ms.date: 09/09/2020
5
+
ms.date: 08/17/2022
6
6
ms.topic: tutorial
7
7
ms.author: jgao
8
8
ms.custom:
9
9
---
10
10
11
11
# Tutorial: Use exported template from the Azure portal
12
12
13
-
In this tutorial series, you've created a template to deploy an Azure storage account. In the next two tutorials, you add an *App Service plan* and a *website*. Instead of creating templates from scratch, you learn how to export templates from the Azure portal and how to use sample templates from the [Azure Quickstart templates](https://azure.microsoft.com/resources/templates/). You customize those templates for your use. This tutorial focuses on exporting templates, and customizing the result for your template. It takes about**14 minutes** to complete.
13
+
In this tutorial series, you create a template to deploy an Azure storage account. In the next two tutorials, you add an **App Service plan** and a **website**. Instead of creating templates from scratch, you learn how to export templates from the Azure portal and how to use sample templates from the [Azure Quickstart Templates](https://azure.microsoft.com/resources/templates/). You customize those templates for your use. This tutorial focuses on exporting templates and customizing the result for your template. This instruction takes**14 minutes** to complete.
14
14
15
15
## Prerequisites
16
16
17
17
We recommend that you complete the [tutorial about outputs](template-tutorial-add-outputs.md), but it's not required.
18
18
19
-
You must have Visual Studio Code with the Resource Manager Tools extension, and either Azure PowerShell or Azure CLI. For more information, see [template tools](template-tutorial-create-first-template.md#get-tools).
19
+
You need to have Visual Studio Code with the Resource Manager Tools extension and either Azure PowerShell or Azure Command-Line Interface (CLI). For more information, see [template tools](template-tutorial-create-first-template.md#get-tools).
20
20
21
21
## Review template
22
22
23
-
At the end of the previous tutorial, your template had the following JSON:
23
+
At the end of the previous tutorial, your template had the following JSON file:
@@ -30,16 +30,16 @@ This template works well for deploying storage accounts, but you might want to a
30
30
31
31
1. Sign in to the [Azure portal](https://portal.azure.com).
32
32
1. Select **Create a resource**.
33
-
1. In **Search the Marketplace**, enter **App Service plan**, and then select **App Service plan**. Don't select **App Service plan (classic)**
33
+
1. In **Search services and Marketplace**, enter **App Service Plan**, and then select **App Service Plan**.
34
34
1. Select **Create**.
35
-
1.Enter:
35
+
1.On the **Create App Service Plan** page, enter the following:
36
36
37
-
-**Subscription**: select your Azure subscription.
38
-
-**Resource Group**: Select **Create new** and then specify a name. Provide a different resource group name than the one you have been using in this tutorial series.
39
-
-**Name**: enter a name for the App service plan.
40
-
-**Operating System**: select**Linux**.
41
-
-**Region**: select an Azure location. For example,**Central US**.
42
-
-**Pricing tier**: to save costs, change the SKU to **Basic B1** (under Dev/Test).
37
+
-**Subscription**: Select your Azure subscription from the drop-down menu.
38
+
-**Resource Group**: Select **Create new** and then specify a name. Provide a different resource group name than the one you've been using in this tutorial series.
39
+
-**Name**: enter a name for the App Service Plan.
40
+
-**Operating System**: Select**Linux**.
41
+
-**Region**: Select an Azure location from the drop-down menu, such as**Central US**.
42
+
-**Pricing Tier**: To save costs, select **Change size** to change the **SKU and size**to **first Basic (B1)**, under **Dev / Test** for less demanding workloads.
> Typically, the exported template is more verbose than you might want when creating a template. For example, the SKU objectin the exported template has five properties. This template works, but you could just use the `name` property. You can start with the exported template, and then modify it as you like to fit your requirements.
65
+
> Typically, the exported template is more verbose than you might want when creating a template. The SKU object, for example, in the exported template has five properties. This template works, but you could just use the `name` property. You can start with the exported template and then modify it as you like to fit your requirements.
66
66
67
67
## Revise existing template
68
68
69
-
The exported template gives you most of the JSON you need, but you need to customize it for your template. Pay particular attention to differences in parameters and variables between your template and the exported template. Obviously, the export process doesn't know the parameters and variables that you've already defined in your template.
69
+
The exported template gives you most of the JSON you need, but you have to customize it for your template. Pay particular attention to differences in parameters and variables between your template and the exported template. Obviously, the export process doesn't know the parameters and variables that you've already defined in your template.
70
70
71
71
The following example highlights the additions to your template. It contains the exported code plus some changes. First, it changes the name of the parameter to match your naming convention. Second, it uses your location parameter for the location of the app service plan. Third, it removes some of the properties where the default value is fine.
72
72
@@ -93,7 +93,7 @@ New-AzResourceGroupDeployment `
93
93
94
94
# [Azure CLI](#tab/azure-cli)
95
95
96
-
To run this deployment command, you must have the [latest version](/cli/azure/install-azure-cli) of Azure CLI.
96
+
To run this deployment command, you need to have the [latest version](/cli/azure/install-azure-cli) of Azure CLI.
97
97
98
98
```azurecli
99
99
az deployment group create \
@@ -106,7 +106,7 @@ az deployment group create \
106
106
---
107
107
108
108
> [!NOTE]
109
-
> If the deployment failed, use the `verbose` switch to get information about the resources being created. Use the `debug` switch to get more information for debugging.
109
+
> If the deployment fails, use the `verbose` switch to get information about the resources you're creating. Use the `debug` switch to get more information for debugging.
110
110
111
111
## Verify deployment
112
112
@@ -115,22 +115,22 @@ You can verify the deployment by exploring the resource group from the Azure por
115
115
1. Sign in to the [Azure portal](https://portal.azure.com).
116
116
1. From the left menu, select **Resource groups**.
117
117
1. Select the resource group you deployed to.
118
-
1. The resource group contains a storage account and an App Service plan.
118
+
1. The resource group contains a storage account and an App Service Plan.
119
119
120
120
## Clean up resources
121
121
122
122
If you're moving on to the next tutorial, you don't need to delete the resource group.
123
123
124
-
If you're stopping now, you might want to clean up the resources you deployed by deleting the resource group.
124
+
If you're stopping now, you might want to delete the resource group.
125
125
126
-
1. From the Azure portal, select **Resource group** from the left menu.
127
-
2.Enter the resource group name in the **Filter by name** field.
128
-
3.Select the resource group name.
126
+
1. From the Azure portal, select **Resource groups** from the left menu.
127
+
2.Type the resource group name in the **Filter for any field...** text field.
128
+
3.Check the box next to **myResourceGroup** and select **myResourceGroup** or your resource group name.
129
129
4. Select **Delete resource group** from the top menu.
130
130
131
131
## Next steps
132
132
133
-
You learned how to export a template from the Azure portal, and how to use the exported template for your template development. You can also use the Azure Quickstart templates to simplify template development.
133
+
You learned how to export a template from the Azure portal and how to use the exported template for your template development. You can also use the Azure Quickstart Templates to simplify template development.
0 commit comments