如何避免在IIS 7.5上的子路径中部署ASP.NET MVC3应用程序 [英] How to avoid deploying ASP.NET MVC3 application in subpath on IIS 7.5

查看:166
本文介绍了如何避免在IIS 7.5上的子路径中部署ASP.NET MVC3应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我将ASP.NET MVC3应用程序部署到WindowsServer 8RC2上的IIS 7.5时,它只能在此URL下访问:mydomain.com/mvcsite而不仅仅是mydomain.com

When I deploy an ASP.NET MVC3 application to an IIS 7.5 on WindowsServer 8RC2 it is only accesible under this url: mydomain.com/mvcsite instead of just mydomain.com

我正在使用MSDeploy从Visual Studio内置的部署包安装应用程序。

I am using MSDeploy to install the app from deployment package built in visual studio.

在IIS上我配置了一个网站,其中包含一个名为'mvcsite的应用程序'。

On the IIS I have a website configured and inside this an Application named 'mvcsite'.

我是否需要重写Url才能使其工作,或者可以在IIS 7.5中配置默认​​根路径?

Do I need Url rewriting to make this work or can some default root path be configured in the IIS 7.5?

推荐答案

在网站的高级设置中(右键点击网站 - > 管理网站 - > 高级设置... ),您可以将物理路径更改为 mvcsite 应用程序所在的路径。

In the Advanced settings of the site (right click on the site -> Manage Web Site -> Advanced Settings...), you can change the Physical path to the path where your mvcsite application resides.

这篇关于如何避免在IIS 7.5上的子路径中部署ASP.NET MVC3应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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