Web部署到Azure时EscapeTextForRegularExpressions错误
问题描述:
在我的asp.ent MVC4项目中,我使用webdeploy将其部署到Azure,并且我之前几次将此项目部署到Azure上的应用程序服务。但突然间我有这个错误。Web部署到Azure时EscapeTextForRegularExpressions错误
"EscapeTextForRegularExpressions" task was not given a value for the required parameter "Text"
我已经找到答案:
添加这个文件放到在其根目录下的web项目。
File Name : *.wpp.targets
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<ExcludeFromPackageFolders Include="Internal">
<FromTarget>*.wpp.targets</FromTarget>
</ExcludeFromPackageFolders>
</ItemGroup>
</Project>
从来没有少我不明白的问题
答
根据你的描述的真正原因,我发现了一个类似的issue注意到IncludeIisSettings
* .csproj的范围内。根据我的测试,如果我指定的<IncludeIisSettings>true</IncludeIisSettings>
与我的csproj,然后当我使用VS的发布向导的Web部署方法,我可能会遇到类似的问题如下:
删除IncludeIisSettings
后或将该值设置为false,那么我可以成功地将我的Web应用程序部署到Azure Web应用程序。
我正在部署到Azure,所以IIS复制不是问题,我没有选择它。 –
永远不要少,非常感谢你我已经修复它,并且我已经在上面添加了答案。 –