32
Deploy and manage Azure resources Overview This tutorial shows how Azure manages resources. You will create your own My Azure Resources, which provides an environment for easy deployments by using PowerShell. When you’re finished, Azure Resource Manager will be able to deploy all the resources by using PowerShell. The following illustration shows the current existing project resources in Azure: You’ll learn these procedures:

Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

  • Upload
    others

  • View
    3

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Deploy and manage Azure resourcesOverviewThis tutorial shows how Azure manages resources. You will create your own My Azure Resources, which provides an environment for easy deployments by using PowerShell. When you’re finished, Azure Resource Manager will be able to deploy all the resources by using PowerShell.

The following illustration shows the current existing project resources in Azure:

You’ll learn these procedures:

How to prepare your computer for Azure development by installing the Azure SDK for .NET. How to set up Visual Studio to help you manage Azure resources. How to create My Azure Resources for the creation of a simple deployment environment. How to publish applications in a simple way after resources are deployed in Azure. How to deploy My Azure Resources by using PowerShell.

Page 2: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Sign up for Microsoft AzureYou need an Azure account to complete this tutorial. You can:

Open an Azure account for free. You get credits that you can use to try paid Azure services. Even after the credits are used up, you can keep the account and use free Azure services and features, such as the Web Apps feature of Azure App Service.

Activate Visual Studio subscriber benefits. Your Visual Studio subscription gives you credits every month that you can use for paid Azure services.

Get credits every month by joining to Visual Studio Dev Essentials.

If you want to get started with Azure App Service before you sign up for an Azure account, go to Try App Service. There, you can immediately create a short-lived starter web app in App Service without a credit card or commitments.

Set up the development environmentTo start, set up your development environment by installing the latest version of the Azure SDK.

Visual Studio 2015▶

Visual Studio 2013▶If you don't have Visual Studio installed, use the link for Visual Studio 2015, and Visual Studio will be installed along with the SDK for Windows Universal Applications.

Alternatively, depending of the type of target project that will use deployed resources, you might need to install Xamarin Platform, including those platforms that are part of the project, or Visual Studio Tools for Apache Cordova.

For the correct operation of scripts that are created with PowerShell and in case you want to deploy My Azure Resources by using PowerShell, you need to install the extensions, PowerShell Tools for Visual Studio 2015 or PowerShell Tools for Visual Studio 2013.

Azure Resource Manager Tools in Visual Studio CodeThe following tutorial shows how to manage Azure resources by using Visual Studio 2015. You can also use Visual Studio Code to manually create resources by using an extension that will integrate into IntelliSense and everything that’s related to Azure resources. As a result, you can easily design the desired template in Visual Studio Code. For more information, see Azure Resource Manager tools.

Page 3: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Create My Azure ResourcesThe first point to consider before you start to manage Azure resources is the needs of the project. This tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented in Microsoft Connect(); //2015, specifically ASPNET5 and MobileApp demos. When you finish this tutorial, 10_Demos_Deployment solution will be completed and you’ll have a simple and effective way to deploy the necessary resources to publish services on Azure later.

Create an Azure Resource project1. In Visual Studio, go to File > New Project > C# or Visual Studio > Cloud, and choose an Azure

Resource Group project.

2. Because you want to create a custom resource group, you should start with an empty template. Select Blank Template in the list of templates.

Page 4: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

3. You can see the files that were created in Solution Explorer.

Deploy-AzureResourceGroup.ps1: A PowerShell script that invokes PowerShell commands to deploy to Azure Resource Manager.

Page 5: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Azuredeploy.json: The resource manager template that defines the infrastructure that you want to deploy to Azure and the parameters that you can provide during deployment. It also defines the dependencies between the resources so they are deployed in the correct order.

Azuredeploy.parameters.json: A parameters file that contains values that the template needs. These are the values that you pass on to customize each deployment.

AzCopy.exe: A tool that’s used by the PowerShell script to copy files from the local storage drop path to the storage account container. This tool is used only if you configure the deployment project to deploy your code along with the template.

Composing the Demo at Microsoft Connect(); //20151. Include the parameters that are required for the template. Open azuredeploy.parameters.json

and include the following code as parameters:

2. Open azuredeploy.json, and the JSON code form deployment template will be deployed. On the left, you see a JSON Outline pane that has the same summary information.

You can add and easily modify existing resources in the JSON document from the JSON Outline pane.

"parameters": { "administratorLogin": { "value": "clinic" }, "databaseName": { "value": "healthclinicdb" }, "administratorLoginPassword": { "value": "healthP2ssw0rd" }}

Page 6: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

3. Add the following parameters and variables to the template.

Page 7: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

"parameters": { "skuName": { "type": "string", "defaultValue": "F1", "allowedValues": [ "F1", "D1", "B1", "B2", "B3", "S1", "S2", "S3", "P1", "P2", "P3", "P4" ], "metadata": { "description": "Describes plan's pricing tier and instance size. Check details at https://azure.microsoft.com/en-us/pricing/details/app-service/" } }, "skuCapacity": { "type": "int", "defaultValue": 1, "minValue": 1, "metadata": { "description": "Describes plan's instance count" } }, "administratorLogin": { "type": "string" }, "administratorLoginPassword": { "type": "securestring" }, "databaseName": { "type": "string" }, "collation": { "type": "string", "defaultValue": "SQL_Latin1_General_CP1_CI_AS" }, "edition": { "type": "string", "defaultValue": "Basic", "allowedValues": [ "Basic", "Standard", "Premium" ] }, "maxSizeBytes": { "type": "string", "defaultValue": "1073741824" }, "requestedServiceObjectiveName": { "type": "string", "defaultValue": "Basic", "allowedValues": [ "Basic", "S0", "S1", "S2",

Page 8: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

4. Add the following resources to the template with the following information:a. App Service Plan (Server Farm) with the name HostingPlan:

b. A Web App with the name Website and the App Service plan > HostingPlan that you created before. Add an Application Settings for Web Apps with the name connectionstrings that’s associated to this Web App:

"parameters": { "skuName": { "type": "string", "defaultValue": "F1", "allowedValues": [ "F1", "D1", "B1", "B2", "B3", "S1", "S2", "S3", "P1", "P2", "P3", "P4" ], "metadata": { "description": "Describes plan's pricing tier and instance size. Check details at https://azure.microsoft.com/en-us/pricing/details/app-service/" } }, "skuCapacity": { "type": "int", "defaultValue": 1, "minValue": 1, "metadata": { "description": "Describes plan's instance count" } }, "administratorLogin": { "type": "string" }, "administratorLoginPassword": { "type": "securestring" }, "databaseName": { "type": "string" }, "collation": { "type": "string", "defaultValue": "SQL_Latin1_General_CP1_CI_AS" }, "edition": { "type": "string", "defaultValue": "Basic", "allowedValues": [ "Basic", "Standard", "Premium" ] }, "maxSizeBytes": { "type": "string", "defaultValue": "1073741824" }, "requestedServiceObjectiveName": { "type": "string", "defaultValue": "Basic", "allowedValues": [ "Basic", "S0", "S1", "S2",

{ "apiVersion": "2015-08-01", "name": "[variables('hostingPlanName')]", "type": "Microsoft.Web/serverfarms", "location": "[resourceGroup().location]", "tags": { "displayName": "HostingPlan" }, "sku": { "name": "[parameters('skuName')]", "capacity": "[parameters('skuCapacity')]" }, "properties": { "name": "[variables('hostingPlanName')]" }}

Page 9: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

c. A SQL Server with the name SqlServer, and an instance of Azure SQL Database with the name Database that’s associated to this server:

{ "apiVersion": "2015-08-01", "name": "[variables('webSiteName')]", "type": "Microsoft.Web/sites", "location": "[resourceGroup().location]", "dependsOn": [ "[concat('Microsoft.Web/serverFarms/', variables('hostingPlanName'))]" ], "tags": { "[concat('hidden-related:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]": "empty", "displayName": "Website" }, "properties": { "name": "[variables('webSiteName')]", "serverFarmId": "[resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName'))]" }, "resources": [ { "apiVersion": "2015-08-01", "type": "config", "name": "connectionstrings", "dependsOn": [ "[concat('Microsoft.Web/Sites/', variables('webSiteName'))]" ], "properties": { "DefaultConnection": { "value": "[concat('Data Source=tcp:', reference(concat('Microsoft.Sql/servers/', variables('sqlserverName'))).fullyQualifiedDomainName, ',1433;Initial Catalog=', parameters('databaseName'), ';User Id=', parameters('administratorLogin'), '@', variables('sqlserverName'), ';Password=', parameters('administratorLoginPassword'), ';')]", "type": "SQLServer" } } } ] },

Page 10: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

d. A Web App with the name MobileApp, and the App Service plan > HostingPlan that was created before.An Application Setting for Web Apps with the name appsettings that’s associated to MobileApp.

{ "name": "[variables('sqlserverName')]", "type": "Microsoft.Sql/servers", "location": "[resourceGroup().location]", "tags": { "displayName": "SqlServer" }, "apiVersion": "2014-04-01-preview", "properties": { "administratorLogin": "[parameters('administratorLogin')]", "administratorLoginPassword": "[parameters('administratorLoginPassword')]" }, "resources": [ { "name": "[parameters('databaseName')]", "type": "databases", "location": "[resourceGroup().location]", "tags": { "displayName": "Database" }, "apiVersion": "2014-04-01-preview", "dependsOn": [ "[concat('Microsoft.Sql/servers/', variables('sqlserverName'))]" ], "properties": { "edition": "[parameters('edition')]", "collation": "[parameters('collation')]", "maxSizeBytes": "[parameters('maxSizeBytes')]", "requestedServiceObjectiveName": "[parameters('requestedServiceObjectiveName')]" } }, { "type": "firewallrules", "apiVersion": "2014-04-01-preview", "dependsOn": [ "[concat('Microsoft.Sql/servers/', variables('sqlserverName'))]" ], "location": "[resourceGroup().location]", "name": "AllowAllWindowsAzureIps", "properties": { "endIpAddress": "0.0.0.0", "startIpAddress": "0.0.0.0" } } ] }

Page 11: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

An Application Setting for Web Apps with the name connectionstrings that’s associated to MobileApp.A Nested Deployment with the name Microsoft.Resources/mobile-notificationhub that’s associated with MobileApp.

Page 12: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

{ "apiVersion": "2015-08-01", "name": "[variables('mobileSiteName')]", "type": "Microsoft.Web/sites", "kind": "mobileapp", "location": "[resourceGroup().location]", "dependsOn": [ "[concat('Microsoft.Web/serverFarms/', variables('hostingPlanName'))]" ], "tags": { "[concat('hidden-related:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]": "empty", "displayName": "MobileApp" }, "properties": { "name": "[variables('mobileSiteName')]", "serverFarmId": "[resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName'))]", "kind": "mobileapp" }, "resources": [ { "apiVersion": "2015-08-01", "name": "appsettings", "type": "config", "dependsOn": [ "[concat('Microsoft.Web/Sites/', variables('mobileSiteName'))]", "[resourceId('Microsoft.NotificationHubs/namespaces/notificationHubs', variables('notificationHubNamespace'), variables('notificationHubName'))]" ], "properties": { "MS_NotificationHubName": "[variables('notificationHubName')]" } }, { "apiVersion": "2015-08-01", "type": "config", "name": "connectionstrings", "dependsOn": [ "[concat('Microsoft.Web/Sites/', variables('mobileSiteName'))]", "[resourceId('Microsoft.NotificationHubs/namespaces/notificationHubs', variables('notificationHubNamespace'), variables('notificationHubName'))]" ], "properties": { "DefaultConnection": { "value": "[concat('Data Source=tcp:', reference(concat('Microsoft.Sql/servers/', variables('sqlserverName'))).fullyQualifiedDomainName, ',1433;Initial Catalog=', parameters('databaseName'), ';User Id=', parameters('administratorLogin'), '@', variables('sqlserverName'), ';Password=', parameters('administratorLoginPassword'), ';')]", "type": "SQLServer" }, "MS_NotificationHubConnectionString": { "value": "[listkeys(resourceId('Microsoft.NotificationHubs/namespaces/notification

Page 13: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

e. A Nested Deployment with the name NotificationHub with other Nested Deployment with the name [concat(variables('notificationHubNamespace'), '/', variables('notificationHubName'))] that’s associated to the Notification Hub:

5. Optionally, related Application Insights resources may be included:

Add an Application Insights for Web Apps resource with the name ApplicationInsights, that’s associated with the App Service plan > HostingPlan and the Web App > Website:

{ "apiVersion": "2015-08-01", "name": "[variables('mobileSiteName')]", "type": "Microsoft.Web/sites", "kind": "mobileapp", "location": "[resourceGroup().location]", "dependsOn": [ "[concat('Microsoft.Web/serverFarms/', variables('hostingPlanName'))]" ], "tags": { "[concat('hidden-related:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]": "empty", "displayName": "MobileApp" }, "properties": { "name": "[variables('mobileSiteName')]", "serverFarmId": "[resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName'))]", "kind": "mobileapp" }, "resources": [ { "apiVersion": "2015-08-01", "name": "appsettings", "type": "config", "dependsOn": [ "[concat('Microsoft.Web/Sites/', variables('mobileSiteName'))]", "[resourceId('Microsoft.NotificationHubs/namespaces/notificationHubs', variables('notificationHubNamespace'), variables('notificationHubName'))]" ], "properties": { "MS_NotificationHubName": "[variables('notificationHubName')]" } }, { "apiVersion": "2015-08-01", "type": "config", "name": "connectionstrings", "dependsOn": [ "[concat('Microsoft.Web/Sites/', variables('mobileSiteName'))]", "[resourceId('Microsoft.NotificationHubs/namespaces/notificationHubs', variables('notificationHubNamespace'), variables('notificationHubName'))]" ], "properties": { "DefaultConnection": { "value": "[concat('Data Source=tcp:', reference(concat('Microsoft.Sql/servers/', variables('sqlserverName'))).fullyQualifiedDomainName, ',1433;Initial Catalog=', parameters('databaseName'), ';User Id=', parameters('administratorLogin'), '@', variables('sqlserverName'), ';Password=', parameters('administratorLoginPassword'), ';')]", "type": "SQLServer" }, "MS_NotificationHubConnectionString": { "value": "[listkeys(resourceId('Microsoft.NotificationHubs/namespaces/notification

{ "apiVersion": "2014-09-01", "name": "[variables('notificationHubNamespace')]", "type": "Microsoft.NotificationHubs/namespaces", "location": "[resourceGroup().location]", "dependsOn": [

], "tags": { "displayName": "NotificationHub" }, "properties": { "namespaceType": "NotificationHub", "messagingSku": 1 }, "resources": [ { "apiVersion": "2014-09-01", "type": "Microsoft.NotificationHubs/namespaces/notificationHubs", "name": "[concat(variables('notificationHubNamespace'), '/', variables('notificationHubName'))]", "location": "[resourceGroup().location]", "dependsOn": [ "[concat('Microsoft.NotificationHubs/namespaces/', variables('notificationHubNamespace'))]" ], "properties": {

} } ] }

Page 14: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

{ "apiVersion": "2014-04-01", "name": "[concat(variables('hostingPlanName'), '-', resourceGroup().name)]", "type": "Microsoft.Insights/autoscalesettings", "location": "East US", "tags": { "[concat('hidden-link:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]": "Resource", "displayName": "AutoScaleSettings" }, "dependsOn": [ "[concat('Microsoft.Web/serverfarms/', variables('hostingPlanName'))]" ], "properties": { "profiles": [ { "name": "Default", "capacity": { "minimum": 1, "maximum": 2, "default": 1 }, "rules": [ { "metricTrigger": { "metricName": "CpuPercentage", "metricResourceUri": "[concat(resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]", "timeGrain": "PT1M", "statistic": "Average", "timeWindow": "PT10M", "timeAggregation": "Average", "operator": "GreaterThan", "threshold": 80.0 }, "scaleAction": { "direction": "Increase", "type": "ChangeCount", "value": 1, "cooldown": "PT10M" } }, { "metricTrigger": { "metricName": "CpuPercentage", "metricResourceUri": "[concat(resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]", "timeGrain": "PT1M", "statistic": "Average", "timeWindow": "PT1H", "timeAggregation": "Average", "operator": "LessThan", "threshold": 60.0 }, "scaleAction": { "direction": "Decrease", "type": "ChangeCount", "value": 1, "cooldown": "PT1H" } } ] }

Page 15: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

6. You have to organize the resources so that they’re generated in a specific order. Resources should be organized as follows:

With this, you will have all available resources to generate simple and quick Azure deployments.

You can download the solution.

Deploy My Azure ResourcesAfter you prepare the resources for the deployment, you can deploy them as many times as necessary.

1. Right click the principal project, and select Deploy > New Deployment.

{ "apiVersion": "2014-04-01", "name": "[concat(variables('hostingPlanName'), '-', resourceGroup().name)]", "type": "Microsoft.Insights/autoscalesettings", "location": "East US", "tags": { "[concat('hidden-link:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]": "Resource", "displayName": "AutoScaleSettings" }, "dependsOn": [ "[concat('Microsoft.Web/serverfarms/', variables('hostingPlanName'))]" ], "properties": { "profiles": [ { "name": "Default", "capacity": { "minimum": 1, "maximum": 2, "default": 1 }, "rules": [ { "metricTrigger": { "metricName": "CpuPercentage", "metricResourceUri": "[concat(resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]", "timeGrain": "PT1M", "statistic": "Average", "timeWindow": "PT10M", "timeAggregation": "Average", "operator": "GreaterThan", "threshold": 80.0 }, "scaleAction": { "direction": "Increase", "type": "ChangeCount", "value": 1, "cooldown": "PT10M" } }, { "metricTrigger": { "metricName": "CpuPercentage", "metricResourceUri": "[concat(resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', variables('hostingPlanName'))]", "timeGrain": "PT1M", "statistic": "Average", "timeWindow": "PT1H", "timeAggregation": "Average", "operator": "LessThan", "threshold": 60.0 }, "scaleAction": { "direction": "Decrease", "type": "ChangeCount", "value": 1, "cooldown": "PT1H" } } ] }

Page 16: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

2. Sign in to Azure if necessary, and select the desired subscription type. Create a new resource group where all resources that will be created are grouped.

3. Optionally, you can click Edit Parameters to modify the deployment parameters.

Page 17: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

The Save passwords option means that the passwords will be saved as plain text in the JSON file. This option is not secure.

4. Click Deploy to implement the project. The implementation may take several minutes. When it’s finished, you can see the deployed resources in the resource group in the Azure portal.

Page 18: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Deploy My Azure Resources by using Azure PowerShellBefore you start to work on the solution, you must be signed in.

To sign in your Azure account, use the Login-AzureRmAccount cmdlet.

You can deploy manually by using PowerShell and have the possibility of creating scripts by using the New-AzureRmResourceGroupDeployment cmdlet.

Page 19: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

You specify the resource group and the location of the template. If your template is not local, you could use the -TemplateUri parameter and specify a URI for the template. You can set the -Mode parameter to either Incremental or Complete. Because Resource Manager performs an incremental update during deployment by default, it is not essential to set -Mode when you want Incremental.

If you are familiar with PowerShell, you can cycle through the available parameters for a cmdlet by typing a minus sign (-) and then pressing the TAB key. This same functionality also works with parameters that you define in your template. As soon as you type the template name, the cmdlet fetches the template, parses it, and adds the template parameters to the command dynamically. This makes it very easy to specify the template parameter values. If you forget a required parameter value, PowerShell prompts you for the value.

You can check the Azure portal to see the deployed resources after the implementation is finished.

Page 20: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

Publish your applicationAfter the resources are deployed in Azure, the application will be implemented in a simpler and quicker way.

In this tutorial, the two existing solutions, 01_Demos_ASPNET5 and 06_Demos_MobileApp, will be deployed in the cloud You can download the solutions from the GitHub repository.

01_Demos_ASPNET51. Open the solution with Visual Studio. You can modify the parameters of the default credentials

that you need to connect to the private website by modifying the appsettings.json file.

Page 21: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

2. Right-click the MyHealth.Web project, and then click Publish. Select Microsoft Azure App Service as a publish target.

Page 22: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

3. Select the desired Azure subscription and look for the resource group that you previously deployed and associated to Web Site.

Page 23: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

4. Click OK. Make sure that you have selected the correct version of DNX (rc1-update1) on the Settings tab.

Page 24: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

5. Click Publish. The web application will be implemented in Azure. When it’s finished, a web browser with the HealthClinic web site will open.

Page 25: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

06_Demos_MobileApp1. Open the solution with Visual Studio.

2. Right-click the MyHealth.MobileApp project, and then click Publish. Select Microsoft Azure App Service as a publish target.

Page 26: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

3. Select the desired Azure subscription, and look for the resource group that you previously deployed and associated to Mobile Site.

Page 27: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

4. Click OK. You can see the different connection parameters on the Connection tab.

Page 28: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

5. Click Publish. The mobile application starts to implement in Azure. When it’s finished, a browser will indicate that the deployment is finished.

Page 29: Microsoftdownload.microsoft.com/download/A/A/5/AA599506-D15D-432E... · Web viewThis tutorial will cover the creation of resources that Azure Resource Manager manages for Demos presented

After both backend services are deployed, you can use the created service URLs in the client applications:

- In the src\MyHealth.Client.Core\AppSettings.cs file, set the following parameters:o ServerUrl to the web service URL.o MobileAPIUrl to the mobile service URL.

- In the src\MyHealth.Client.Cordova\content\app\modulers\shared\services\configService.ts file, set the Azure_API_URL parameter to the mobile service URL.

Other suggested topics to explore Creation and deploying Azure resource groups through Visual Studio. Installation and management of extensions in Visual Studio Code. Deployment of Demo presented at Microsoft Connect(); //2015 from the existing

documentation in GitHub. Using Azure PowerShell with Azure Resource Manager. Deploying a Resource Group with an Azure Resource Manager template. Azure Developer Tools – Learn more about the tools and find the recently released installers.