MVC 3网站从本地主机部署到IIS(目录列表被拒绝) [英] Deploy MVC 3 Site From LocalHost to IIS (Directory Listing Denied)
问题描述
我有我的网站:
http://localhost:55649/
我想将它移动到:
I want to move it to:
\\10.0.0.169\Inetpub\wwwroot\MyOldWebsite\NewSite
我读到这的http:/ /haacked.com/archive/2011/05/25/bin-deploying-asp-net-mvc-3.aspx 并点击添加部署大会,但我得到的错误:
I read this http://haacked.com/archive/2011/05/25/bin-deploying-asp-net-mvc-3.aspx and clicked "Add Deployable Assemblies" but I get the error:
拒绝目录列表
这虚拟目录不允许列出的内容。
This Virtual Directory does not allow contents to be listed.
我能做些什么来解决这个错误,使网站的工作?
What can I do to fix this error to make the site work?
推荐答案
当你得到消息它往往是因为路由不能正常工作,该网站正试图找到一个默认文档(在MVC3不存在)。如果路由不工作这通常意味着IIS不跨preting它作为一个MVC3站点或不知道的MVC3的网站是什么。
When you get that message it tends to be because routing isn't working and the site is trying to find a default document (which in MVC3 doesn't exist). If routing isn't working that generally means IIS isn't interpreting it as an MVC3 site or doesn't know what an MVC3 site is.
- 您是否有服务器的.NET Framework 4.0和MVC3安装?
- 是使用你的网站一个.NET 4.0的应用程序池?
- 您的新目录中是否有适当的权限?根据不同的应用/服务器安全这可以改变。但一般IUSR需要读取权限。
这篇关于MVC 3网站从本地主机部署到IIS(目录列表被拒绝)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!