Creating a Cloud Service Project

You create a cloud service project from Visual Studio (File, New, Project). You select the Cloud option on the left of the New Project dialog; you then select the template Azure Cloud Service. Figure 12.70 shows an example.

Image

FIGURE 12.70 Select Azure Cloud Service to get started working with PaaS directly in Azure.

The Azure Cloud Service template then presents a few sub options, as shown in Figure 12.71. You use this dialog to select the type of cloud services you want to add to your solution. Your options include a web role for building a web user interface, the work role for creating web jobs that run in the background, a role for WCF services, and others. You can always add services at a later date. In this case, we added just the ASP.NET Web Role.

Image

FIGURE 12.71 Choose various cloud services to add to your project.

Visual Studio then prompts you on what type of ASP.NET application you want to create. You can choose between the standard site templates that are supported by the current version of Azure. Figure 12.72 shows options at the time of writing.

Image

FIGURE 12.72 Select the remaining project parameters, such as ASP.NET template.

Visual Studio then creates two projects and adds them to a solution. The MVC Web role is simply an ASP.NET MVC website. The other project is an Azure configuration definition project for working with your Azure Cloud Service. Figure 12.73 shows an example inside Solution Explorer.

Image

FIGURE 12.73 The Azure Cloud Service project along with the related website.


Tip

You can create your website using a standard project template and then configure it later as a cloud service application. This proves to be especially useful if your website project already exists. To make this happen, right-click your project and choose Convert, Convert to Microsoft Azure Cloud Service Project.


..................Content has been hidden....................

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