Rob
Rob

Reputation: 1390

ASP.NET MVC 3 RC and Azure?

I keep running into problems creating a Windows Azure Cloud Service and trying to add an MVC 2 (which ends up being an MVC 3) Web Role. Initially it says MVC 2 but I was really hoping to get an MVC 3 app. Then it says that it will be an MVC 3 Web Role. Once I've gone through the steps, I get the following error:

Cannot add the item because the item to add it to is not a solution folder or the solution.

This happens no matter what I do to add it. Worker Role, standard Web Role work fine. Only the MVC 3 Web Role fails. Is there something special that I need to do to get this to work? Or how do I get started making an MVC 3 Azure app and combining it with a Worker Role?

Upvotes: 13

Views: 3107

Answers (3)

JacobE
JacobE

Reputation: 8141

This is a great article: How To Publish an ASP.NET MVC 3 App to Windows Azure

It is written for the ASP.NET MVC 3 RTM version.

Upvotes: 6

user94559
user94559

Reputation: 60143

SDK 1.3 will fix this (that using the MVC web role template when MVC 3 is installed doesn't work). SDK 1.3 ships later this year.

Yes, for manually adding an MVC 3 web role, I think it works to create a new MVC 3 web app, mark the MVC binaries as "copy local" (since they're not GAC'd in the cloud), and then "add existing web role in solution" to hook it up as a web role for your project. (What I described should be exactly what Jim's talking about in that blog post.)

Upvotes: 6

Jakub Konecki
Jakub Konecki

Reputation: 46008

I think this post describes MVC2 on Azure but it should work with MVC3 as well:

Migrating an Existing ASP.NET App to run on Windows Azure

Upvotes: 1

Related Questions