Mono MVC 2 home route doesn't work Mono MVC 2 home route doesn't work nginx nginx

Mono MVC 2 home route doesn't work


I actually ran into the same problem and solved it (at least in my situation) by complete mistake...

In the nginx walkthrough on the mono project's site, it says to enter these lines in your nginx.conf file:

index index.html index.htm default.aspx Default.aspx;fastcgi_index Default.aspx;

Well, I set this up in the exact same way (or so I thought) on two VMs. Problem is, one VM had it's root url work and one didn't. What it turned out to be was that I forgot the semi-colon on the 'index' line on the VM that worked, so that the 'fastcgi_index' line was interpreted as part of the 'index' line.

So on the VM that didn't work, I removed that semi-colon. And guess what? It worked. So then I added the semi-colon and entirely removed the 'fastcgi_index' line and it still worked. So based on this anecdotal evidence and some guess work, I'd say that the 'fastcgi_index' line should not be included in MVC applications. Well, at least MVC 3, I haven't tested anything else.


Did you follow the nginx configuration from this page?: http://www.mono-project.com/FastCGI_Nginx

My guess would be the default document is getting in the way.