在IIS 7 / Server 2008的部署ASP.NET MVC应用程序的最佳方式? [英] Best way to deploy an ASP.NET MVC app on IIS 7 / Server 2008?

查看:127
本文介绍了在IIS 7 / Server 2008的部署ASP.NET MVC应用程序的最佳方式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

到目前为止,唯一成功的策略,我已经能够用得到通过如下:

So far, the only successful strategy I've been able to get by with is the following:


  1. 配置YOURAPP.Web为使用本地IIS Web服务器,并设置项目地址= 的http://本地主机/ yourapp名.web

  2. 单击创建虚拟目录

  3. 在IIS管理器中,确保经典.net应用程序池中选择了

  4. 名为ASP.NET MVC的
  5. 添加通配符映射*指向IsapiModule

但我真的不喜欢具有全ASP.NET管道的想法请求的任何资源(JavaScript文件,样式表,图像等...),这是与通配符映射正是发生时调用。

BUT I don't really like the idea of having the full ASP.NET pipeline invoked when requesting any resource (javascript file, stylesheet, image, etc...) which is exactly what happens with the wildcard mapping.

那么,有没有办法解决?

So is there a way around this?

有没有在IIS 7上运行的应用程序的MVC更好的方法?

Is there a better method to running mvc apps on IIS 7?

我要建议肯定愿意因为我不是那么满意,我走到这一步。

I'm definitely open to suggestions as I'm not all that satisfied with what I got so far.

谢谢 - WG

推荐答案

确认IIS7的托管管道模式设置为集成。这一直是这样做(我)让我的MVC应用程序在IIS7运行平稳的一个最重要的事情。
下面是一个<一个href=\"http://blogs.dovetailsoftware.com/blogs/kmiller/archive/2008/10/07/deploying-an-asp-net-mvc-web-application-to-iis7.aspx\"相对=nofollow>不错的博客文章也。
在开发应用程序,我不得不使用Visual Studio开发服务器运行的应用程序没有问题。

Make sure IIS7's "Managed pipeline mode" is set to "Integrated". That has been the single most important thing to do (for me) to get my MVC app running smoothly on IIS7. Here's a good blog post too. When developing the app, I have had no issues using the "Visual Studio Development Server" for running the app.

这篇关于在IIS 7 / Server 2008的部署ASP.NET MVC应用程序的最佳方式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆