This QuickStart helps you deploy your first ASP. NET Web app to Azure app service within minutes. After completing this tutorial, you will be able to launch and run a simple Web app in the cloud. All of the actions completed in this tutorial are eligible for the 1-dollar trial condition.
Before you begin
This tutorial demonstrates how to build an ASP. NET Web app and deploy it to Azure using Visual Studio 2017. If you have not already installed Visual Studio 2017, you can download and use the free Visual Studio Community Edition. Make sure that Azure development is enabled during the installation of Visual Studio. If you don't have an Azure subscription, you can create a trial account before you start.
Step 1: Configure vs 2017 Connect to China Azure
1. Create a new JSON file AadProvider.Configuration.json with the following file contents:
{
"AuthenticationQueryParameters": null,
"AsmEndPoint": "https://management.core.chinacloudapi.cn",
"Authority": "https://login.chinacloudapi.cn/",
"AzureResourceManagementEndpoint": "https://management.chinacloudapi.cn/",
"AzureResourceManagementAudienceEndpoints": [ "https://management.core.chinacloudapi.cn/" ],
"ClientIdentifier": "872cd9fa-d31f-45e0-9eab-6e460a02d1f1",
"EnvironmentName": "Mooncake",
"GraphEndpoint": "https://graph.chinacloudapi.cn",
"MsaHomeTenantId": "f577cd82-810c-43f9-a1f6-0cc532871050",
"NativeClientRedirect": "urn:ietf:wg:oauth:2.0:oob",
"PortalEndpoint": "http://manage.windowsazure.cn",
"ResourceEndpoint": "https://management.core.chinacloudapi.cn/",
"ValidateAuthority": true,
"VisualStudioOnlineEndpoint": "https://app.vssps.visualstudio.com/",
"VisualStudioOnlineAudience": "499b84ac-1321-427f-aa17-267ca6975798"
}
2. Connect to the Chinese area Azure service
A. ensure that Visual Studio is logged out and closed.
B. Delete the%temp%\servicehub folder (the detailed path is C:\Users\%USERPROFILE%\AppData\Local\Temp\servicehub).
c. Copy the previously created JSON file (AadProvider.Configuration.json) to the%localappdata%\. Identityservice\aadconfigurations (The detailed path is C:\Users\%USERPROFILE%\AppData\Local\. Identityservice\aadconfigurations, the Aadconfigurations folder may not exist and need to be created manually).
d. Restart VS and add a Chinese Azure account.
3. Add a Chinese area Azure account in Cloud Explorer
4. Click Apply to view the resources in the subscription in Cloud Explorer
Step 2: Create an ASP. NET Web app
1. In Visual Studio, create a new project using Ctrl+shift+n.
2. In the New Project dialog box, click Visual C # > Web > ASP. NET Framework.
3. Name the application Myfirstazurewebapp, and then click OK.
4. You can deploy any type of ASP. NET Web application to Azure. In this tutorial, you select the MVC template and make sure that authentication is set to No authentication. Click OK.
Step 3: Publish to Azure
1. Right-click the Myfirstazurewebapp project in Solution Explorer and choose Publish.
2. Make sure Azure app service is selected, and then click Publish.
3. The Create App Service dialog box opens to help you create all the azure resources you need to run your ASP. NET Web app in Azure. Enter the name of the Web app you want, select the subscription, create a new resource group, select the application plan, and refer to the detailed parameters section here. Finally click Create.
4. When the creation is complete, the ASP. NET Web App is automatically published to Azure (first release), and the published Azure web App is launched in the default browser.
For more steps, click to
Welcome to Exchange
A research institute graduate student [email protected]
Create a. NET application in an Azure Web app