Skip to content

Commit 56a6995

Browse files
authored
Merge pull request #219473 from msjasteppe/iot-bicep-addition
New Bicep quickstart
2 parents e14131e + e0e91d1 commit 56a6995

File tree

4 files changed

+219
-14
lines changed

4 files changed

+219
-14
lines changed

articles/healthcare-apis/iot/deploy-08-new-ps-cli.md

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
---
2-
title: Using Azure PowerShell and Azure CLI to deploy the MedTech service with Azure Resource Manager (ARM) templates - Azure Health Data Services
3-
description: In this article, you'll learn how to use Azure PowerShell and Azure CLI to deploy the MedTech service using an Azure Resource Manager template.
2+
title: Deploy the MedTech service using an Azure Resource Manager template and Azure PowerShell or Azure CLI - Azure Health Data Services
3+
description: In this quickstart, you'll learn how to deploy the MedTech service using an Azure Resource Manager template and Azure PowerShell or Azure CLI
44
author: msjasteppe
55
ms.service: healthcare-apis
66
ms.subservice: fhir
77
ms.topic: quickstart
8-
ms.date: 11/22/2022
8+
ms.date: 11/28/2022
99
ms.author: jasteppe
1010
---
1111

12-
# Quickstart: Using Azure PowerShell and Azure CLI to deploy the MedTech service with Azure Resource Manager templates
12+
# Quickstart: Deploy the MedTech service using an Azure Resource Manager template and Azure PowerShell or Azure CLI
1313

14-
In this article, you'll learn how to use Azure PowerShell and Azure CLI to deploy the MedTech service using an Azure Resource Manager (ARM) template. When you call the template from PowerShell or CLI, it provides automation that enables you to distribute your deployment to large numbers of developers. Using PowerShell or CLI allows for modifiable automation capabilities that will speed up your deployment configuration in enterprise environments.
14+
In this quickstart, you'll learn how to use Azure PowerShell or Azure CLI to deploy the MedTech service using an Azure Resource Manager (ARM) template. When you call the template from PowerShell or CLI, it provides automation that enables you to distribute your deployment to large numbers of developers. Using PowerShell or CLI allows for modifiable automation capabilities that will speed up your deployment configuration in enterprise environments.
1515

1616
For more information about ARM templates, see [What are ARM templates?](./../../azure-resource-manager/templates/overview.md).
1717

@@ -21,14 +21,14 @@ The ARM template used in this article is available from the [Azure Quickstart Te
2121

2222
The ARM template will help you automatically configure and deploy the following resources. Each one can be modified to meet your deployment requirements.
2323

24-
- Azure Event Hubs namespace and device message event hub (the device message event hub is named: **devicedata**).
25-
- Azure event hub consumer group (named **$Default**).
26-
- Azure event hub sender role (named **devicedatasender**).
24+
- Azure Event Hubs namespace and device message event hub (the device message event hub is named: `devicedata`).
25+
- Azure event hub consumer group (named `$Default`).
26+
- Azure event hub sender role (named `devicedatasender`).
2727
- Azure Health Data Services workspace.
2828
- Azure Health Data Services Fast Healthcare Interoperability Resources (FHIR®) service.
2929
- Azure Health Data Services MedTech service. This resource includes setup for:
30-
- [system-assigned managed identity](../../active-directory/managed-identities-azure-resources/overview.md) access roles needed to read from the device message event hub (named **Azure Events Hubs Receiver**)
31-
- system-assigned managed identity access roles needed to read and write to the FHIR service (named **FHIR Data Writer**)
30+
- [system-assigned managed identity](../../active-directory/managed-identities-azure-resources/overview.md) access roles needed to read from the device message event hub (named `Azure Events Hubs Receiver`)
31+
- system-assigned managed identity access roles needed to read and write to the FHIR service (named `FHIR Data Writer`)
3232
- An output file containing the ARM template deployment results (named **medtech_service_ARM_template_deployment_results.txt**). The file is located in the directory from which you ran the script.
3333

3434
If you need to see a diagram with information on the MedTech service deployment, there's an architecture overview at [Choose a deployment method](deploy-iot-connector-in-azure.md#deployment-architecture-overview). This diagram shows the data flow steps of deployment and how MedTech service processes data into a FHIR Observation.
@@ -86,7 +86,6 @@ Complete the following five steps to deploy the MedTech service using Azure Powe
8686
For example: `New-AzResourceGroup -name ArmTestDeployment -location southcentralus`
8787

8888
> [!IMPORTANT]
89-
>
9089
> For a successful deployment of the MedTech service, you'll need to use numbers and lowercase letters for the basename of your resources. The minimum basename requirement is three characters with a maximum of 16 characters.
9190
9291
5. Use the following code to deploy the MedTech service using the ARM template:
@@ -133,7 +132,6 @@ Complete the following five steps to deploy the MedTech service using Azure CLI:
133132
For example: `az group create --resource-group ArmTestDeployment --location southcentralus`
134133

135134
> [!IMPORTANT]
136-
>
137135
> For a successful deployment of the MedTech service, you'll need to use numbers and lowercase letters for the basename of your resources.
138136
139137
5. Use the following code to deploy the MedTech service using the ARM template:
@@ -184,7 +182,7 @@ For example: `az group delete --resource-group ArmTestDeployment`
184182
185183
## Next steps
186184

187-
In this article, you learned how to use Azure PowerShell and Azure CLI to deploy the MedTech service using an Azure Resource Manager (ARM) template. To learn more about other methods of deployment, see
185+
In this article, you learned how to use Azure PowerShell or Azure CLI to deploy the MedTech service using an Azure Resource Manager (ARM) template. To learn more about other methods of deployment, see
188186

189187
> [!div class="nextstepaction"]
190188
> [Choosing a method of deployment for MedTech service in Azure](deploy-iot-connector-in-azure.md)
Lines changed: 203 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,203 @@
1+
---
2+
title: Deploy the MedTech service using a Bicep file and Azure PowerShell or Azure CLI - Azure Health Data Services
3+
description: In this quickstart, you'll learn how to deploy the MedTech service using a Bicep file and Azure PowerShell or Azure CLI
4+
author: msjasteppe
5+
ms.service: healthcare-apis
6+
ms.subservice: fhir
7+
ms.topic: quickstart
8+
ms.date: 11/28/2022
9+
ms.author: jasteppe
10+
---
11+
12+
# Quickstart: Deploy the MedTech service using a Bicep file and Azure PowerShell or Azure CLI
13+
14+
In this quickstart, you'll learn how to:
15+
16+
> [!div class="checklist"]
17+
> - Use Azure PowerShell or Azure CLI to deploy an instance of the MedTech service using a Bicep file.
18+
19+
Bicep is a domain-specific language (DSL) that uses declarative syntax to deploy Azure resources. In a Bicep file, you define the infrastructure you want to deploy to Azure, and then use that file throughout the development lifecycle to repeatedly deploy your infrastructure. Your resources are deployed in a consistent manner.
20+
21+
Bicep provides concise syntax, reliable type safety, and support for code reuse. Bicep offers a first-class authoring experience for your infrastructure-as-code solutions in Azure.
22+
23+
For more information about Bicep, see [What is Bicep?](/azure/azure-resource-manager/bicep/overview?tabs=bicep)
24+
25+
## Deployment prerequisites
26+
27+
To begin your deployment and complete the quickstart, you must have the following prerequisites:
28+
29+
- An active Azure subscription account. If you don't have an Azure subscription, see [Subscription decision guide](/azure/cloud-adoption-framework/decision-guides/subscriptions/).
30+
31+
- Owner or Contributor and User Access Administrator role assignments in the Azure subscription. For more information, see [What is Azure role-based access control?](../../role-based-access-control/overview.md)
32+
33+
- The Microsoft.HealthcareApis and Microsoft.EventHub resource providers registered with your Azure subscription. To learn more about registering resource providers, see [Azure resource providers and types](../../azure-resource-manager/management/resource-providers-and-types.md).
34+
35+
- [Azure PowerShell](/powershell/azure/install-az-ps) and/or [Azure CLI](/cli/azure/install-azure-cli) installed locally.
36+
- For Azure PowerShell, you'll also need to install [Bicep CLI](/azure/azure-resource-manager/bicep/install#windows) to deploy the Bicep file used in this quickstart.
37+
38+
When you have these prerequisites, you're ready to deploy the Bicep file.
39+
40+
## Review the Bicep file
41+
42+
The Bicep file used for this deployment is available from the [Azure Quickstart Templates](/samples/azure/azure-quickstart-templates/iotconnectors/) site using the `main.bicep` file located on [GitHub](https://github.com/azure/azure-quickstart-templates/tree/master/quickstarts/microsoft.healthcareapis/workspaces/iotconnectors/).
43+
44+
Locally save the Bicep file as `main.bicep`. You'll need to have the working directory of your Azure PowerShell or Azure CLI console pointing to the location where this file is saved.
45+
46+
## Deploy the MedTech service with the Bicep file and Azure PowerShell
47+
48+
Complete the following five steps to deploy the MedTech service using Azure PowerShell:
49+
50+
1. Sign-in into Azure.
51+
52+
```azurepowershell
53+
Connect-AzAccount
54+
```
55+
56+
2. Set your Azure subscription deployment context using your subscription ID. To learn how to get your subscription ID, see [Get subscription and tenant IDs in the Azure portal](/azure/azure-portal/get-subscription-tenant-id).
57+
58+
```azurepowershell
59+
Set-AzContext <AzureSubscriptionId>
60+
```
61+
62+
For example: `Set-AzContext abcdef01-2345-6789-0abc-def012345678`
63+
64+
3. Confirm the location you want to deploy in. See the [Products available by region](https://azure.microsoft.com/global-infrastructure/services/?products=health-data-services) site for the current Azure regions where Azure Health Data Services is available.
65+
66+
You can also review the **location** section of the locally saved `main.bicep` file.
67+
68+
If you need a list of the Azure regions location names, you can use this code to display a list:
69+
70+
```azurepowershell
71+
Get-AzLocation | Format-Table -Property DisplayName,Location
72+
```
73+
74+
4. If you don't already have a resource group created for this quickstart, you can use this code to create one:
75+
76+
```azurepowershell
77+
New-AzResourceGroup -name <ResourceGroupName> -location <AzureRegion>
78+
```
79+
80+
For example: `New-AzResourceGroup -name BicepTestDeployment -location southcentralus`
81+
82+
> [!IMPORTANT]
83+
> For a successful deployment of the MedTech service, you'll need to use numbers and lowercase letters for the basename of your resources. The minimum basename requirement is three characters with a maximum of 16 characters.
84+
85+
5. Use the following code to deploy the MedTech service using the Bicep file:
86+
87+
```azurepowershell
88+
New-AzResourceGroupDeployment -ResourceGroupName <ResourceGroupName> -TemplateFile main.bicep -basename <BaseName> -location <AzureRegion>
89+
```
90+
91+
For example: `New-AzResourceGroupDeployment -ResourceGroupName BicepTestDeployment -TemplateFile main.bicep -basename abc123 -location southcentralus`
92+
93+
## Deploy the MedTech service with the Bicep file and Azure CLI
94+
95+
Complete the following six steps to deploy the MedTech service using Azure CLI:
96+
97+
1. Sign-in into Azure.
98+
99+
```azurecli
100+
az login
101+
```
102+
2. Set your Azure subscription deployment context using your subscription ID. To learn how to get your subscription ID, see [Get subscription and tenant IDs in the Azure portal](/azure/azure-portal/get-subscription-tenant-id).
103+
104+
```azurecli
105+
az account set <AzureSubscriptionId>
106+
```
107+
108+
For example: `az account set abcdef01-2345-6789-0abc-def012345678`
109+
110+
3. Confirm the location you want to deploy in. See the [Products available by region](https://azure.microsoft.com/global-infrastructure/services/?products=health-data-services) site for the current Azure regions where Azure Health Data Services is available.
111+
112+
You can also review the **location** section of the locally saved `main.bicep` file.
113+
114+
If you need a list of the Azure regions location names, you can use this code to display a list:
115+
116+
```azurecli
117+
az account list-locations -o table
118+
```
119+
120+
4. If you don't already have a resource group created for this quickstart, you can use this code to create one:
121+
122+
```azurecli
123+
az group create --resource-group <ResourceGroupName> --location <AzureRegion>
124+
```
125+
126+
For example: `az group create --resource-group BicepTestDeployment --location southcentralus`
127+
128+
> [!IMPORTANT]
129+
> For a successful deployment of the MedTech service, you'll need to use numbers and lowercase letters for the basename of your resources.
130+
131+
5. Use the following code to deploy the MedTech service using the Bicep file:
132+
133+
```azurecli
134+
az deployment group create --resource-group BicepTestDeployment --template-file main.bicep --parameters basename=<BaseName> location=<AzureRegion>
135+
```
136+
137+
For example: `az deployment group create --resource-group BicepTestDeployment --template-file main.bicep --parameters basename=abc location=southcentralus`
138+
139+
## Review deployed resources and access permissions
140+
141+
When deployment is completed, the following resources and access roles are created in the Bicep file deployment:
142+
143+
- Azure Event Hubs namespace and device message event hub. In this deployment, the device message event hub is named `devicedata`.
144+
145+
- An event hub consumer group. In this deployment, the consumer group is named `$Default`.
146+
147+
- The Azure Event Hubs Data Sender role. In this deployment, the sender role is named `devicedatasender`.
148+
149+
- A Health Data Services workspace.
150+
151+
- A Health Data Services Fast Healthcare Interoperability Resources (FHIR&#174;) service.
152+
153+
- An instance of the MedTech service for Health Data Services, with the required [system-assigned managed identity](../../active-directory/managed-identities-azure-resources/overview.md) roles:
154+
155+
- For the device message event hub, the Azure Events Hubs Data Receiver role is assigned in the [Access control section (IAM)](../../role-based-access-control/overview.md) of the device message event hub.
156+
157+
- For the FHIR service, the FHIR Data Writer role is assigned in the [Access control section (IAM)](../../role-based-access-control/overview.md) of the FHIR service.
158+
159+
## Post-deployment mappings
160+
161+
After you've successfully deployed an instance of the MedTech service, you'll still need to provide conforming and valid device and FHIR destination mappings.
162+
163+
- To learn more about device mappings, see [How to configure device mappings](how-to-use-device-mappings.md).
164+
165+
- To learn more about FHIR destination mappings, see [How to configure FHIR destination mappings](how-to-use-fhir-mappings.md).
166+
167+
## Clean up Azure PowerShell deployed resources
168+
169+
When your resource group and deployed Bicep file resources are no longer needed, delete the resource group, which deletes the resources in the resource group.
170+
171+
```azurepowershell
172+
Remove-AzResourceGroup -Name <ResourceGroupName>
173+
```
174+
175+
For example: `Remove-AzResourceGroup -Name BicepTestDeployment`
176+
177+
## Clean up Azure CLI deployed resources
178+
179+
When your resource group and deployed Bicep file resources are no longer needed, delete the resource group, which deletes the resources in the resource group.
180+
181+
```azurecli
182+
az group delete --name <ResourceGroupName>
183+
```
184+
185+
For example: `az group delete --resource-group BicepTestDeployment`
186+
187+
> [!TIP]
188+
> For a step-by-step tutorial that guides you through the process of creating a Bicep file, see [Build your first Bicep template](/training/modules/build-first-bicep-template/).
189+
190+
## Next steps
191+
192+
In this article, you learned how to use Azure PowerShell or Azure CLI to deploy an instance of the MedTech service using a Bicep file. To learn more about other methods of deploying the MedTech service, see
193+
194+
> [!div class="nextstepaction"]
195+
> [Choosing a method of deployment for the MedTech service in Azure](deploy-iot-connector-in-azure.md)
196+
197+
> [!div class="nextstepaction"]
198+
> [How to deploy the MedTech service with a Azure Resource Manager template](deploy-02-new-button.md)
199+
200+
> [!div class="nextstepaction"]
201+
> [How to manually deploy the MedTech service with Azure portal](deploy-03-new-manual.md)
202+
203+
FHIR&#174; is a registered trademark of Health Level Seven International, registered in the U.S. Trademark Office and is used with their permission.

articles/healthcare-apis/iot/index.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ landingContent:
4444
url: deploy-02-new-button.md
4545
- text: Azure PowerShell and Azure CLI
4646
url: deploy-08-new-ps-cli.md
47+
- text: Azure Bicep
48+
url: deploy-new-bicep-ps-cli.md
4749
- text: Azure portal
4850
url: deploy-03-new-manual.md
4951

articles/healthcare-apis/iot/toc.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,10 @@ items:
2323
href: deploy-iot-connector-in-azure.md
2424
- name: Azure Resource Manager template
2525
href: deploy-02-new-button.md
26-
- name: Azure PowerShell and Azure CLI
26+
- name: Azure PowerShell or Azure CLI
2727
href: deploy-08-new-ps-cli.md
28+
- name: Azure Bicep
29+
href: deploy-new-bicep-ps-cli.md
2830
- name: Azure portal - Prerequisites
2931
href: deploy-03-new-manual.md
3032
- name: Azure portal - Configure

0 commit comments

Comments
 (0)