我注意到,当我通过msdeploy部署应用程序时,所有的url重写(IIS 7.5)都被删除了。如何才能防止这种情况发生,或者如何将url重新写入msdeploy的一部分?
发布于 2011-04-11 18:14:57
好吧,我只是没想清楚。实际上,我不需要对MSDeploy做任何事情。我在IIS管理器中创建的设置只是直接转储到我的应用程序根web.config中。部署新的配置文件总是覆盖我在IIS中设置的内容。解决方案是将重定向放到web.config中并进行部署。
例如:
<system.webServer>
<rewrite>
<rules>
<rule name="weddings1" stopProcessing="true">
<match url="weddings.html" />
<action type="Redirect" url="weddings" />
</rule>
</rules>
</rewrite>
</system.webServer>https://serverfault.com/questions/258412
复制相似问题