Skip to content

Commit 79cabad

Browse files
authored
Merge pull request #193579 from schaffererin/0331-app-configuration-quickstart
Creating new Bicep quickstart - Azure App Configuration
2 parents 5c8cf24 + 30c4a5d commit 79cabad

File tree

3 files changed

+127
-1
lines changed

3 files changed

+127
-1
lines changed

articles/azure-app-configuration/TOC.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,12 @@
3737
href: quickstart-feature-flag-azure-functions-csharp.md
3838
- name: Java Spring
3939
href: quickstart-feature-flag-spring-boot.md
40+
- name: Bicep
41+
href: quickstart-bicep.md
42+
displayName: ARM, Resource Manager, Template
4043
- name: ARM template
4144
href: quickstart-resource-manager.md
42-
displayName: ARM, azure resource manager template
45+
displayName: Resource Manager
4346
- name: .NET App in Visual Studio
4447
href: /visualstudio/azure/vs-azure-tools-connected-services-app-configuration
4548
- name: Tutorials
Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
---
2+
title: Create an Azure App Configuration store using Bicep
3+
titleSuffix: Azure App Configuration
4+
description: Learn how to create an Azure App Configuration store using Bicep.
5+
author: schaffererin
6+
ms.author: v-eschaffer
7+
ms.date: 05/06/2022
8+
ms.service: azure-app-configuration
9+
ms.topic: quickstart
10+
ms.custom: subject-armqs, devx-track-azurepowershell, mode-arm
11+
---
12+
13+
# Quickstart: Create an Azure App Configuration store using Bicep
14+
15+
This quickstart describes how you can use Bicep to:
16+
17+
- Deploy an App Configuration store.
18+
- Create key-values in an App Configuration store.
19+
- Read key-values in an App Configuration store.
20+
21+
[!INCLUDE [About Bicep](../../includes/resource-manager-quickstart-bicep-introduction.md)]
22+
23+
## Prerequisites
24+
25+
If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
26+
27+
## Review the Bicep file
28+
29+
The Bicep file used in this quickstart is from [Azure Quickstart Templates](https://azure.microsoft.com/resources/templates/app-configuration-store-kv/).
30+
31+
:::code language="bicep" source="~/quickstart-templates/quickstarts/microsoft.appconfiguration/app-configuration-store-kv/main.bicep":::
32+
33+
Two Azure resources are defined in the Bicep file:
34+
35+
- [Microsoft.AppConfiguration/configurationStores](/azure/templates/microsoft.appconfiguration/2020-07-01-preview/configurationstores): create an App Configuration store.
36+
- [Microsoft.AppConfiguration/configurationStores/keyValues](/azure/templates/microsoft.appconfiguration/2020-07-01-preview/configurationstores/keyvalues): create a key-value inside the App Configuration store.
37+
38+
With this Bicep file, we create one key with two different values, one of which has a unique label.
39+
40+
## Deploy the Bicep file
41+
42+
1. Save the Bicep file as **main.bicep** to your local computer.
43+
1. Deploy the Bicep file using either Azure CLI or Azure PowerShell.
44+
45+
# [CLI](#tab/CLI)
46+
47+
```azurecli
48+
az group create --name exampleRG --location eastus
49+
az deployment group create --resource-group exampleRG --template-file main.bicep --parameters configStoreName=<store-name>
50+
```
51+
52+
# [PowerShell](#tab/PowerShell)
53+
54+
```azurepowershell
55+
New-AzResourceGroup -Name exampleRG -Location eastus
56+
New-AzResourceGroupDeployment -ResourceGroupName exampleRG -TemplateFile ./main.bicep -configStoreName "<store-name>"
57+
```
58+
59+
---
60+
61+
> [!NOTE]
62+
> Replace **\<store-name\>** with the name of the App Configuration store.
63+
64+
When the deployment finishes, you should see a message indicating the deployment succeeded.
65+
66+
## Review deployed resources
67+
68+
Use Azure CLI or Azure PowerShell to list the deployed resources in the resource group.
69+
70+
# [CLI](#tab/CLI)
71+
72+
```azurecli-interactive
73+
az resource list --resource-group exampleRG
74+
```
75+
76+
# [PowerShell](#tab/PowerShell)
77+
78+
```azurepowershell-interactive
79+
Get-AzResource -ResourceGroupName exampleRG
80+
```
81+
82+
---
83+
84+
You can also use the Azure portal to list the resources:
85+
86+
1. Sign in to the Azure portal.
87+
1. In the search box, enter *App Configuration*, then select **App Configuration** from the list.
88+
1. Select the newly created App Configuration resource.
89+
1. Under **Operations**, select **Configuration explorer**.
90+
1. Verify that two key-values exist.
91+
92+
## Clean up resources
93+
94+
When no longer needed, use Azure CLI or Azure PowerShell to delete the resource group and its resources.
95+
96+
# [CLI](#tab/CLI)
97+
98+
```azurecli-interactive
99+
az group delete --name exampleRG
100+
```
101+
102+
# [PowerShell](#tab/PowerShell)
103+
104+
```azurepowershell-interactive
105+
Remove-AzResourceGroup -Name exampleRG
106+
```
107+
108+
---
109+
110+
You can also use the Azure portal to delete the resource group:
111+
112+
1. Navigate to your resource group.
113+
1. Select **Delete resource group**.
114+
1. A tab will appear. Enter the resource group name and select **Delete**.
115+
116+
## Next steps
117+
118+
To learn about adding feature flag and Key Vault reference to an App Configuration store, check out the ARM template examples.
119+
120+
- [app-configuration-store-ff](https://azure.microsoft.com/resources/templates/app-configuration-store-ff/)
121+
- [app-configuration-store-keyvaultref](https://azure.microsoft.com/resources/templates/app-configuration-store-keyvaultref/)

articles/azure-resource-manager/bicep/toc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,8 @@
9393
href: ../../dms/create-dms-bicep.md?toc=/azure/azure-resource-manager/bicep/toc.json
9494
- name: DevOps
9595
items:
96+
- name: App Configuration
97+
href: ../../azure-app-configuration/quickstart-bicep.md?toc=/azure/azure-resource-manager/bicep/toc.json
9698
- name: DevTest Labs
9799
href: ../../devtest-labs/create-lab-windows-vm-bicep.md?toc=/azure/azure-resource-manager/bicep/toc.json
98100
- name: Integration

0 commit comments

Comments
 (0)