Deploying the Logic App ARM template

In this demo, we are going to deploy the Logic App ARM template, which can be downloaded from the GitHub repository that was provided in the Technical requirements section at the beginning of this chapter. The Logic App reads out RSS information on the CNN website and sends out an email from an Office 365 email account with the RSS item details. To deploy the Logic App ARM template, perform these steps:

  1. Download the ARM template from the GitHub repository. If you want to look at the properties of the template, you can use Visual Studio Code or Notepad. The download link for Visual Studio Code is provided in the Technical requirements section as well. Create a new folder on your C drive and name it MyTemplates. Save the ARM templates in this directory.
  2. We are going to deploy this template using PowerShell. Open PowerShell and add the following code (replace the subscription name):
    1. First, we need to log into the Azure account:
Connect-AzAccount
    1. If necessary, select the right subscription:
Select-AzSubscription -SubscriptionId "********-****-****-****-***********"
    1. Create a resource group:
New-AzResourceGroup -Name PacktLogicAppResourceGroup -Location EastUS
    1. Deploy the template inside your Azure subscription as follows:
New-AzResourceGroupDeployment `
-Name PacktDeployment `
-ResourceGroupName PacktLogicAppResourceGroup `
-TemplateFile c:MyTemplates emplate.json
  1. After deployment, you need to go to the Logic App settings and configure an Outlook account that can be used to send out the email. By default, the account details will be empty. To configure an account, open PacktLogicApp in the Logic App Designer and open the Connections step. There, click Invalid connection and connect to an Office 365 account, as shown in the following screenshot:

Adding an email account to the Logic App
You should get familiar with the different parts of the ARM template as they could be part of the exam questions. 
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset