我正在做的事情应该很简单。在IIS6中,我可以转到网站上的“属性”并从中创建/删除应用程序状态。然而,我不能在我的生活中弄清楚如何将网站本身(不是它下面的虚拟目录)转换成应用程序!使IIS7.5网站成为应用程序
最终,我的问题是使用Visual Studio 2010中的发布功能,因为它给了我这个错误:It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
我假设这是因为该网站未配置为应用程序。
如果我在我的网站下创建一个虚拟目录,并将它提升到一个应用程序(通过右击它并选择Convert to Application
),那么一切都很好。但我根本无法弄清楚如何做到这一点网站本身,我需要这样做,因为我需要这个托管在www.domain.com/
而不是www.domain.com/appname/
的MVC2网站。我是否全部错了?我是否正确使用VS2010或者我在IIS中缺少一个选项?