Web services – deploy to Microsoft Azure

Microsoft Azure deployment for web services.

.

Assumptions and prerequisites

You are registered in the DPS907 or WSA web services course, in Fall 2015 or later.

A web service was created with Visual Studio 2013 Update 4 or later.

You have a Microsoft Account (signup.live.com).

If your app uses Entity Framework, then Code First Migrations have been configured.

.

Redeem your Azure Pass

Recently, you received an Azure Pass.

In a browser, visit this page to redeem the pass: microsoftazurepass.com

.

Microsoft Azure services, and planning to use them

For this course, we will use Microsoft Azure Web Apps and SQL databases.

In the next two months, you will create and use a small number of Web Apps. The recommended name for your first web app will be a composite of your part of your College “myseneca.ca” account name, and a suffix “-ws2015labs”.

For example, if your College “myseneca.ca” login name is ‘pmcintyr’, you will create a web app to host your labs, with this Web App name:

pmcintyr-ws2015labs.azurewebsites.net

The database server name will be auto-generated by Azure. However, we can choose the SQL database name. For your labs, the sql database name will be:

LabsDatabase

During the creation of the database server, you must create or define credentials. This is a normal task, and similar to your past experience with database servers. If you wish, you can use the same login name and password as your Microsoft Account.

In the next section, you will implement these plans.

.

Login to the Microsoft Azure portal

In a browser, login to the Microsoft Azure management portal, using your Microsoft Account credentials.

The portal will give you a brief tour of its capabilities. Follow the tour and learn. Then, look around on your own.

.

Create a Web App and SQL database

The following procedure will enable you to create

Use the names suggested above:

Website name: pmcintyr-ws2015labs.azurewebsites.net

Region: East US

“Create a new SQL database”

Connection string: DataContext

Database name: LabsDatabase

On a “New SQL database server”

(database) Server login name: (we suggest re-using your Microsoft Account login name)

Region: East US

Watch this video to learn how to complete these tasks.

.

A hierarchy for your Azure-hosted projects

The Azure web app that you created (above) will be able to host your work for Lab 3, Lab 4, Lab 5, and maybe others.

How?

By creating a “root” project now, and creating Azure “virtual applications” later.

Before watching the next video, create another simple project (maybe named LabsRoot):

  • Web application
  • MVC web app only (no Web API)
  • No authentication

Run it locally, to ensure that it works correctly.

Then, watch this video, which will explain how to publish this “root” project to your Azure web app.

.

Deploy your web app to Azure

Watch this video to learn how to deploy your Lab 3 web app to Azure.

You must have completed all previously-described tasks.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

Advertisements
%d bloggers like this: