views:

98

answers:

1

Hi folks,

I'm trying to get the stock standard ASP.NET MVC (official release, version 1.0) to work/run. The trick? I'm trying to get it working under IIS7 instead of the built in Visual Studio Development Server (aka. Cassini).

What happens? It never goes to the default home page but to a LOGIN page.

Pre-info

  1. OS = Win 7 RTM.
  2. VS2008 Team Suit + ASP.NET MVC 1.0 + VS2008 SP1 (installed in that order).

Steps to reproduce :-

  1. Install IIS7. Make sure IIS6 Metbase and config thingy is also 'ticked'.
  2. Start VS2008
  3. File -> New -> Project -> Web -> ASP.NET MVC Web Application
  4. Start - Debug. All works 100% fine. The default "Welcome to ASP.NET MVC!" resource displays.
  5. Start Internet Information Services (IIS) Manager
  6. Sites -> Add Website -> Give it a name and make the Physical Path point to the folder of the MVC web app i made in step #3. I made this site have a port #5555.
  7. Start your fav browser. goto http://localhost:5555

Ok, here's the first error. IIS can't read the web.config file due to permissions problem. So i then...

  1. Goto the root folder which contains all the MVC website code. For me it was C:\Projects\TestSite1
  2. Right click on that folder from #8, Security -> Edit -> Add -> IIS_IUSR -> OK -> OK -> OK.
  3. Reload the website in your browser.

Ok #2. Now the config file can be read BUT we're getting 302'd to /Account/LogOn url instead?!!

Can someone please explain what is going on? please :)

A: 

Try this answer on SO can-not-acces-page-without-authentication

Malcolm Frexner