Windows azure platform (14) deploy a local azure project to a cloud server

Source: Internet
Author: User
Tags visual studio 2010

We have learned about the previous chapter.

1) how to create a Windows azure Project

2) how to add web role and worker role

3) introduced the project content and configuration file

4) Learn How to debug the azure Project

5) have a certain understanding of worker role

 

This chapter describes how to deploy a project that has been successfully debugged locally to a cloud server.

1. Local Compilation

For the Visual Studio project in the previous chapter, Please create or reopen a Windows azure project.

Then open the hellowindowsazure project --> roles --> mywebrole --> right-click --> Property

Change instance to 3 and VM Size to small.

This indicates that the azure web site has three computing nodes for Automatic Load Balancing. The configuration of each computing node is small.

 

Modify the default. aspxs page of mywebrole.

 

Make sure that no error occurs in build --> build solution.

 

Select hellowindowsazure project, right-click package

The pop-up window appears. If you want to use the cloud configuration file, selectServiceconfiguration. Cloud. cscfg

Otherwise, selectServiceconfiguration. Local. cscfg

The folder is displayed, which contains two files with the suffixes cspkg and cscfg. Do not close the folder window first.

 

2. Cloud settings

Open your browser, enter https://windows.azure.com/default.aspx, and enter the Windows Live ID that you have bound to the Windows azure service.

Click managed services, storage accounts, and CDN, and select managed services

 

Then select create managed service.

Select subscription: The Windows azure service account that you subscribe.

Enter the server name: Add a name to your azure service.

Enter the service URL prefix.: This URL is used to access your web application after you deploy the web application on the Windows azure cloud computing platform. If the URL you set is the same as another user's URL, Windows azure will remind you to reset it.

Select region or GEO Group: You can select the Windows azure cloud computing data center closest to your physical location. The windows azure platform currently has eight public data centers around the world. You can"Select region or GEO Group"Select any data center for deployment. That is to say, you can deploy managed services in a single azure account in different data centers. When selecting a data center, we generally observe the following two principles:

    • Proximity principle: the data center should be geographically close to the main users. For example, customers are mainly located in Europe and usually select "Western Europe" or "Eastern Europe" data centers.
    • Consistency principle: ApplicationProgramThe hosted service, storage service, and SQL azure used should be in the same data center as much as possible to achieve the fastest access speed, while avoiding the cost of data transmission across data centers.
    • The data center closest to Mainland China is located in Hong Kong, East Asia, so I chose East Asia.

(A geo Group means that you can create an alias for Windows azure data centers in east Asia and Central America. For example, you can name a data center in East Asia "Hong Kong data center ", in the future, you can select the alias "Hong Kong Data Center" to set up windows azure data centers.)

Geographic group: allows you to bring managed services and storage services on Windows azure closer to physical locations, and even deploy them on the same cluster.

For more information about geographic groups, see the importance of Windows azure platform () Windows azure affinity groups

 

Deployment Options:

A Windows azure web site has two environments: a transitional environment and a production environment.

URLs generated in the transition environment are composed of guids, which are usually used for testing and internal release sites.

The URL generated in the production environment is the service URL entered by the user, which is usually used for commercial use and official release of the site.

Deployment Name:We can name the deployment, such as version 1.0 and Version 1.1.

 

Select the two folder locations after Visual Studio 2010 package.

 

Select OK after uploading.

 

Upload my compiled site files to Windows azure.

Generally, the entire release process is about 10-15 minutes. The process is as follows:

1. upload your cspkg and cscfg

2. After the upload is complete, apply for a computing node

3. Start the computing node

4. Deploy your applications to each computing node.

 

After successful deployment:

Reader's observation: we can see that this azure website has three computing nodes, all of which are production environments.

The status is ready, indicating that my release is successful.

 

Then I can use the URL set above:

Http://leihelloazure.cloudapp.net/

To visit my first Windows azure site.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.