正在使用TFS 2017内部部署来构建我们的代码。我用以下参数使用msbuild任务。元素<publishData>无法识别,或在此上下文中不受支持
/p:DeployOnBuild=true /p:AllowedReferenceRelatedFileExtensions=none /p:PublishProfile="$(Build.SourcesDirectory)\Source\PublishSettings\xxx.azurewebsites.net.publishsettings" /p:VisualStudioVersion=14.0 /p:Configuration=Release
登录:
2017-12-27T07:43:15.6823390Z Publish Pipeline Deploy phase Stage PipelineCopyAllFilesToOneFolderForMsdeploy
2017-12-27T07:43:15.6823390Z Package:
2017-12-27T07:43:15.6823390Z Invoking Web Deploy to generate the package with the following settings:
2017-12-27T07:43:15.6979640Z $(LocalIisVersion) is 0
2017-12-27T07:43:15.6979640Z $(DestinationIisVersion) is 0
2017-12-27T07:43:15.6979640Z $(UseIis) is True
2017-12-27T07:43:15.6979640Z $(IisUrl) is http://localhost:7372/
2017-12-27T07:43:15.6979640Z $(IncludeIisSettings) is False
2017-12-27T07:43:15.6979640Z $(_DeploymentUseIis) is False
2017-12-27T07:43:15.6979640Z $(DestinationUseIis) is False
2017-12-27T07:43:15.6979640Z GetMSDeployInstalledVersionPath:
2017-12-27T07:43:15.6979640Z $(_DefaultMSDeployMaxVersion) is 3
2017-12-27T07:43:15.6979640Z $(_MSDeployVersionsToTry) is 9.0
2017-12-27T07:43:15.6979640Z $(MSDeployPath) is C:\Program Files (x86)\IIS\Microsoft Web Deploy V3\
2017-12-27T07:43:15.6979640Z GenerateMsdeployManifestFiles:
2017-12-27T07:43:15.6979640Z Generate source manifest file for Web Deploy package/publish ...
我得到了下面的错误。
The element <publishData> is unrecognized, or not supported in this context
我测试了我的发布是从蔚蓝的下载设置,它的工作原理与Visual Studio部署完全正常。我的web api项目是.net 4.6.1。
注意:只有这个项目不能正常构建,.Net 4.5.1的所有其他项目都可以构建,在我们的本地tfs代理中完美无瑕。
如果你构建,手动发布它通过MSBuild命令,结果如何?您可以在OneDrive上共享构建日志吗(建立在本地tfs代理上)? –
什么是适用于构建/发布的publishsettings文件的详细代码? –
您可以在OneDrive上共享示例项目吗? –