Tuesday, 3 December 2013

Deploying to Windows Azure

If you’d like to avoid hosting your own website and take advantage of the increasing amount of “cloud capacity” available to you, one other deployment and hosting option is Microsoft’s cloud hosting platform, Windows Azure. With Windows Azure, you can concentrate on your application and let Microsoft worry about the infrastructure required to host it on the Internet.

The Simple steps for deploying your application to the cloud using Windows Azure are
  • Creating a Windows Azure Account
  • Creating a New Windows Azure Website
  • Publishing a Windows Azure Website via Source Control


When you’re finished, you will have a public website hosted in the cloud.



Creating a Windows Azure Account

Before you can deploy your website to the cloud using Windows Azure, you must first register for a Windows Azure account. To do so, visit the Windows Azure website, find and click the link that says “Free trial” or “Register,” and create your new account. Once your account is created, you’ll be taken to the Windows Azure Management Portal, the online portal for managing your cloud hosting services

Creating a New Windows Azure Website

To create a new website using the Windows Azure portal, click the New menu at the bottom-left of the page and choose the “Web Site” option, then click “Create with Database” to open the New Web Site wizard. Fill out the information for your new site, such as the DNS name of the site and the region (i.e., data center) in which the site should be hosted. Since the EBuy application requires a database to store its information, choose the “Create new SQL database” option from the Database dropdown list.

The next few steps will help you configure your new database; the default values are generally fine for most small websites. When you’re done providing all the information for your new site and its database, click “Create Web Site” to create your new site.

After providing Windows Azure with plenty of time to create and provision your new web application, click on the web application from the list of applications to begin managing it.

Publishing a Windows Azure Website via Source Control

By far the easiest way to deploy your application to a Windows Azure website is to leverage the built-in support for source control publishing via the Team Foundation Server (TFS) or Git source control systems.

However, keep in mind that the overall process you’re about to see is the same process that’s used with the Git source control publishing method.

To begin using TFS source control publishing, click the “Set up TFS publishing” link from your Azure website dashboard to bring up the TFS source control configuration wizard. Then, enter the username that you used to create your TFS Preview account in the previous chapter (or click on the link to create a new TFS Preview account if you have not already done so) and click on the “Authorize now” link to authorize Windows Azure to access your TFS Preview account.

After you’ve successfully authorized Windows Azure, go to the next dialog and select the source control project that you’d like to link with this website, then click the checkmark to complete. After a few seconds, Windows Azure will link your website to the TFS project that you specified.

With this link in place, every checkin that you perform on your TFS project will trigger a new build of your project in TFS. Upon each successful build, the newly built website will be deployed to Windows Azure and your new changes will be live, without any additional effort on your part.









No comments:

Post a Comment