Create And Publish The Azure Cloud Service Through Visual Studio

Step 1

Create Cloud project.

Open Visual Studio, create new project and choose Azure Cloud Service.

Give a name to the project and click OK.



Step 2

Add Role. After clicking OK, it will ask you to add Role, like Web Role or Worker Role,  or both. Here, we are going to choose both.

Click on the arrows to add or remove to the right or vice versa.



Step 3

Choose template.

We are going with MVC.  Here, I am choosing MVC template and clicking OK.



It will create Web Role and Worker Role project in your solution.



Step 4

Build and publish.

Build your project, right click on your project and choose publish.



Step 5

Publish and sign In.

In this, it will ask your Azure Account credentials to get the subscription details.




Hence, choose your subscription and click next.

Step 6

Create Cloud Service.

If you do not have Cloud Service already, then it will pop up for the details.



If you already have Cloud Service in your subscription, choose create from dropdown.



Hence, give the details in the popup.



Click create.

Step 7

Enable remote desktop.

Check the check box to enable the remote desktop for the Cloud Service.



It will ask for the user, password and the expiration date.



Step 8

In advanced settings, choose deployment label and storage account for the Service.



Step 9

Publish summary.

Click publish and wait for the result.



Configure Role Modules.



Afterwards, it will gives you an error.



Step 10

Solve the error and publish.

Right click the Web Role and uncheck the Connection Strings section.







Do the same task for the Worker Role.

Right click on the project and choose publish.

It will show you a popup, which will ask to publish summary again.

Click publish.







You can see Cloud Service on the portal, as shown below:



Your Service is ready in the in the Web Browser.