我有一个遗留的Web应用程序,我最近已迁移到VSTS(来自旧的TFS2008服务器),现在正尝试在VSTS中设置CI / CD。
我有一个内部构建代理,声称成功构建了解决方案(即构建通过),但生成的人工制品是一个空的“drop”文件夹,我不明白。< / p>
由于这是一个内部部署的构建服务器,我有能力戳它的文件系统,我可以看到<agent root>\_work\20\a
确实是空的,即使相关的网站已经构建,并且甚至预编译(即要部署的东西确实存在于<agent root>\_work\20\s\PrecompiledWeb
)所以我错过了连接两个众所周知的点,超出了“ASP.NET(PREVIEW)”构建模板给我的开始?
解决方案文件很简单:
Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 15 VisualStudioVersion = 15.0.27004.2009 MinimumVisualStudioVersion = 10.0.40219.1 Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = "HorizonDashboard", "Source\Code\HorizonDashboard", "{0D9EC6BB-C1A9-4A12-BAA0-61B7205307E6}" ProjectSection(WebsiteProperties) = preProject SccProjectName = "SAK" SccAuxPath = "SAK" SccLocalPath = "SAK" SccProvider = "SAK" TargetFrameworkMoniker = ".NETFramework,Version%3Dv3.5" ProjectReferences = "{3F6ED2DF-3AAC-40E5-8DFF-101EBD2BCA77}|MscTools.dll;{83226B78-CB43-4BCC-BEFA-B3CCB4E387CB}|MscCommon.dll;{F4A2CB09-7ED0-40AC-810A-489FEB7A3D45}|MscUk.Printing.dll;" Debug.AspNetCompiler.VirtualPath = "/HorizonDashboard" Debug.AspNetCompiler.PhysicalPath = "Source\Code\HorizonDashboard\" Debug.AspNetCompiler.TargetPath = "PrecompiledWeb\HorizonDashboard\" Debug.AspNetCompiler.Updateable = "true" Debug.AspNetCompiler.ForceOverwrite = "true" Debug.AspNetCompiler.FixedNames = "false" Debug.AspNetCompiler.Debug = "True" Release.AspNetCompiler.VirtualPath = "/HorizonDashboard" Release.AspNetCompiler.PhysicalPath = "Source\Code\HorizonDashboard\" Release.AspNetCompiler.TargetPath = "PrecompiledWeb\HorizonDashboard\" Release.AspNetCompiler.Updateable = "true" Release.AspNetCompiler.ForceOverwrite = "true" Release.AspNetCompiler.FixedNames = "false" Release.AspNetCompiler.Debug = "False" VWDPort = "5343" SlnRelativePath = "Source\Code\HorizonDashboard\" EndProjectSection EndProject Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "MyCompany.Tools", "Utility\Code\MyCompany.Tools\MyCompany.Tools.vbproj", "{3F6ED2DF-3AAC-40E5-8DFF-101EBD2BCA77}" EndProject ...
(稍微编辑下来以适应此处)构建日志看起来都非常明智,因为Web项目多年来一直没有被修改过:
2017-11-22T12:37:25.5742010Z ##[section]Starting: Phase 1 2017-11-22T12:37:25.5771997Z Current agent version: '2.124.0' 2017-11-22T12:37:26.7802445Z ##[section]Starting: Initialize Job 2017-11-22T12:37:26.7922437Z Prepare build directory. 2017-11-22T12:37:26.8532483Z Set build variables. 2017-11-22T12:37:26.8592461Z Download all required tasks. 2017-11-22T12:37:26.9112479Z ##[section]Finishing: Initialize Job 2017-11-22T12:37:26.9532524Z ##[section]Starting: Get Sources 2017-11-22T12:37:27.0302567Z Prepending Path environment variable with directory containing 'tf.exe'. 2017-11-22T12:37:27.0312583Z Setting environment variable TFVC_BUILDAGENT_POLICYPATH 2017-11-22T12:37:27.0322584Z Querying workspace information. 2017-11-22T12:37:29.3233381Z ##[command]tf vc get /version:68375 /recursive /overwrite C:\agent\_work\20\s /loginType:OAuth /login:.,******** /noprompt 2017-11-22T12:37:30.3883833Z C:\agent\_work\20\s\MasterReference\Test\MyCompany.CommonTests: 2017-11-22T12:37:30.3904477Z Replacing MyCompany.CommonTests.vbproj 2017-11-22T12:37:30.4043870Z 2017-11-22T12:37:30.4043870Z C:\agent\_work\20\s\Utility\Test\MyCompany.Tools.Test: 2017-11-22T12:37:30.4043870Z Replacing MyCompany.Tools.Test.vbproj 2017-11-22T12:37:30.4053852Z 2017-11-22T12:37:30.4053852Z C:\agent\_work\20\s\Utility\Test\MyCompany.Printing.Test: 2017-11-22T12:37:30.4053852Z Replacing MyCompany.Printing.Test.vbproj 2017-11-22T12:37:31.0074074Z ##[section]Finishing: Get Sources 2017-11-22T12:37:40.3047646Z ##[section]Starting: Build solution 2017-11-22T12:37:40.3057684Z ============================================================================== 2017-11-22T12:37:40.3057684Z Task : Visual Studio Build 2017-11-22T12:37:40.3057684Z Description : Build with MSBuild and set the Visual Studio version property 2017-11-22T12:37:40.3057684Z Version : 1.125.0 2017-11-22T12:37:40.3057684Z Author : Microsoft Corporation 2017-11-22T12:37:40.3057684Z Help : [More Information](https://go.microsoft.com/fwlink/?LinkID=613727) 2017-11-22T12:37:40.3057684Z ============================================================================== 2017-11-22T12:37:42.2128393Z ##[command]"C:\agent\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.125.0\ps_modules\MSBuildHelpers\vswhere.exe" -version [15.0,16.0) -latest -format json 2017-11-22T12:37:42.7308577Z ##[command]"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\msbuild.exe" "C:\agent\_work\20\s\Horizon.sln" /nologo /nr:false /dl:CentralLogger,"C:\agent\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.125.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=317b7114-2199-4657-88e7-322c162344f7|SolutionDir=C:\agent\_work\20\s"*ForwardingLogger,"C:\agent\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.125.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll" /p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation="C:\agent\_work\20\a\\" /p:platform="any cpu" /p:configuration="release" /p:VisualStudioVersion="15.0" /p:_MSDeployUserAgent="VSTS_f214a5e7-a852-44ab-a368-c1d8cf3736ca_build_282_29739" 2017-11-22T12:37:42.8568940Z Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch. 2017-11-22T12:37:42.8978900Z Build started 22/11/2017 12:37:42. 2017-11-22T12:37:43.0938699Z Project "C:\agent\_work\20\s\Horizon.sln" on node 1 (default targets). 2017-11-22T12:37:43.0958797Z ValidateSolutionConfiguration: 2017-11-22T12:37:43.0958797Z Building solution configuration "release|any cpu". 2017-11-22T12:37:43.4928823Z Project "C:\agent\_work\20\s\Horizon.sln" (1) is building "C:\agent\_work\20\s\HorizonDashboard.metaproj" (2) on node 1 (default targets). 2017-11-22T12:37:43.4928823Z Project "C:\agent\_work\20\s\HorizonDashboard.metaproj" (2) is building "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\MyCompany.Tools.vbproj" (3) on node 1 (default targets). 2017-11-22T12:37:43.5089198Z CoreCompile: 2017-11-22T12:37:43.5089198Z Skipping target "CoreCompile" because all output files are up-to-date with respect to the input files. 2017-11-22T12:37:43.5149173Z _CopyFilesMarkedCopyLocal: 2017-11-22T12:37:43.5149173Z Touching "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\obj\Release\MyCompany.Tools.vbproj.CopyComplete". 2017-11-22T12:37:43.5178950Z CopyFilesToOutputDirectory: 2017-11-22T12:37:43.5178950Z MyCompany.Tools -> C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\MyCompany.Tools.dll 2017-11-22T12:37:43.5299775Z Done Building Project "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\MyCompany.Tools.vbproj" (default targets). 2017-11-22T12:37:43.6828940Z Project "C:\agent\_work\20\s\HorizonDashboard.metaproj" (2) is building "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\MyCompany.Common.vbproj" (4) on node 1 (default targets). 2017-11-22T12:37:43.6828940Z Project "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\MyCompany.Common.vbproj" (4) is building "C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\MyCompany.Printing.csproj" (5:2) on node 1 (default targets). 2017-11-22T12:37:43.6828940Z CoreCompile: 2017-11-22T12:37:43.6828940Z Skipping target "CoreCompile" because all output files are up-to-date with respect to the input files. 2017-11-22T12:37:43.6859251Z CopyFilesToOutputDirectory: 2017-11-22T12:37:43.6859251Z MyCompany.Printing -> C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\bin\Release\MyCompany.Printing.dll 2017-11-22T12:37:43.6868979Z Copying file from "obj\Release\MyCompany.Printing.pdb" to "bin\Release\MyCompany.Printing.pdb". 2017-11-22T12:37:43.6928941Z Done Building Project "C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\MyCompany.Printing.csproj" (default targets). 2017-11-22T12:37:44.0679081Z CoreResGen: 2017-11-22T12:37:44.0679081Z No resources are out of date with respect to their source files. Skipping resource generation. 2017-11-22T12:37:44.1679144Z CoreCompile: 2017-11-22T12:37:44.1689119Z C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn\vbc.exe /noconfig /baseaddress:11000000 /imports:Microsoft.VisualBasic,System,System.Collections,System.Data,System.Diagnostics,System.Linq /optioncompare:Binary /optionexplicit+ /optionstrict+ /nowarn:42016,42017,42018,42019,42032,42353,42354,42355 /nostdlib /removeintchecks- /rootnamespace:MyCompany /sdkpath:C:\Windows\Microsoft.NET\Framework\v2.0.50727 /highentropyva- /doc:obj\Release\MyCompany.Common.xml /define:"CONFIG=\"Release\",TRACE=-1,_MyType=\"Windows\",PLATFORM=\"AnyCPU\"" /reference:"C:\agent\_work\20\s\3rdParty\Microsoft Office 2003\Main\Lib\Microsoft.Office.Interop.Excel.dll","C:\agent\_work\20\s\3rdParty\SQL Server\Microsoft.SqlServer.Types.dll",C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\MyCompany.Tools.dll,C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\bin\Release\MyCompany.Printing.dll,C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\Office.dll,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.ComponentModel.DataAnnotations.dll",C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Configuration.dll,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Core.dll",C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Data.dll,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Data.Linq.dll",C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.DirectoryServices.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\System.Runtime.Serialization.dll","C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Web.Extensions.dll",C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Windows.Forms.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /main:"MyCompany.(None)" /debug- /optimize+ /out:obj\Release\MyCompany.Common.dll /ruleset:"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Team Tools\Static Analysis Tools\\Rule Sets\MinimumRecommendedRules.ruleset" /resource:obj\Release\MyCompany.Locations.CustomerSites.resources /resource:Resources\MyCompany.Logo.emf,MyCompany.MyCompany.Logo.emf /target:library /warnaserror+ /utf8output Accounting\AccountingWeek.vb Accounting\Characteristics.vb Accounting\Currencies.vb Accounting\Currency.vb Accounting\ExchangeRate.vb Accounting\ExchangeRateHelper.vb Testing\PropertyChangeMonitor.vb Testing\XmlValidator.vb UserActionLog.vb ValidationError.vb XmlSqlHelper.vb 2017-11-22T12:37:44.1909458Z Using shared compilation with compiler from directory: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn 2017-11-22T12:37:46.4009983Z 2017-11-22T12:37:46.4189983Z _CopyFilesMarkedCopyLocal: 2017-11-22T12:37:46.4189983Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\bin\Release\MyCompany.Printing.pdb" to "bin\Release\MyCompany.Printing.pdb". 2017-11-22T12:37:46.4209998Z Touching "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\obj\Release\MyCompany.Common.vbproj.CopyComplete". 2017-11-22T12:37:46.4250044Z CopyFilesToOutputDirectory: 2017-11-22T12:37:46.4250044Z Copying file from "obj\Release\MyCompany.Common.dll" to "bin\Release\MyCompany.Common.dll". 2017-11-22T12:37:46.4290072Z MyCompany.Common -> C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Common.dll 2017-11-22T12:37:46.4290072Z Copying file from "obj\Release\MyCompany.Common.xml" to "bin\Release\MyCompany.Common.xml". 2017-11-22T12:37:46.4389949Z Done Building Project "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\MyCompany.Common.vbproj" (default targets). 2017-11-22T12:37:46.5420560Z Build: 2017-11-22T12:37:46.5420560Z No way to resolve conflict between "Microsoft.SqlServer.Types, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" and "Microsoft.SqlServer.Types, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91". Choosing "Microsoft.SqlServer.Types, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" arbitrarily. 2017-11-22T12:37:46.5420560Z Consider app.config remapping of assembly "Microsoft.SqlServer.Types, Culture=neutral, PublicKeyToken=89845dcd8080cc91" from Version "11.0.0.0" [C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Types\11.0.0.0__89845dcd8080cc91\Microsoft.SqlServer.Types.dll] to Version "12.0.0.0" [C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\Microsoft.SqlServer.Types.dll] to solve conflict and get rid of warning. 2017-11-22T12:37:46.5640054Z ##[warning]C:\agent\_work\20\s\HorizonDashboard.metaproj(0,0): Warning MSB3247: Found conflicts between different versions of the same dependent assembly. In Visual Studio, double-click this warning (or select it and press Enter) to fix the conflicts; otherwise, add the following binding redirects to the "runtime" node in the application configuration file: 2017-11-22T12:37:46.5640054Z C:\agent\_work\20\s\HorizonDashboard.metaproj : warning MSB3247: Found conflicts between different versions of the same dependent assembly. In Visual Studio, double-click this warning (or select it and press Enter) to fix the conflicts; otherwise, add the following binding redirects to the "runtime" node in the application configuration file: 2017-11-22T12:37:46.5650049Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\MyCompany.Tools.dll" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Tools.dll". 2017-11-22T12:37:46.5650049Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\Microsoft.ReportViewer.WinForms.dll" to "Source\Code\HorizonDashboard\\Bin\Microsoft.ReportViewer.WinForms.dll". 2017-11-22T12:37:46.5660117Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\MyCompany.Tools.xml" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Tools.xml". 2017-11-22T12:37:46.5670163Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\de\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\de\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5690107Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\es\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\es\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5700350Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\fr\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\fr\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5721059Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\it\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\it\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5740121Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\ja\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ja\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5751155Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\ko\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ko\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5770606Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\pt\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\pt\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5780522Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\ru\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ru\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5820109Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\zh-CHS\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\zh-CHS\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5840323Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Tools\bin\Release\zh-CHT\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\zh-CHT\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.5850331Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Common.dll" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Common.dll". 2017-11-22T12:37:46.5860191Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\Microsoft.Office.Interop.Excel.dll" to "Source\Code\HorizonDashboard\\Bin\Microsoft.Office.Interop.Excel.dll". 2017-11-22T12:37:46.5960087Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\Microsoft.SqlServer.Types.dll" to "Source\Code\HorizonDashboard\\Bin\Microsoft.SqlServer.Types.dll". 2017-11-22T12:37:46.5990172Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Tools.dll" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Tools.dll". 2017-11-22T12:37:46.6000155Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Printing.dll" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Printing.dll". 2017-11-22T12:37:46.6000155Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\office.dll" to "Source\Code\HorizonDashboard\\Bin\office.dll". 2017-11-22T12:37:46.6020134Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\Microsoft.ReportViewer.WinForms.dll" to "Source\Code\HorizonDashboard\\Bin\Microsoft.ReportViewer.WinForms.dll". 2017-11-22T12:37:46.6060085Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\stdole.dll" to "Source\Code\HorizonDashboard\\Bin\stdole.dll". 2017-11-22T12:37:46.6060085Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Common.xml" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Common.xml". 2017-11-22T12:37:46.6100118Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Tools.xml" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Tools.xml". 2017-11-22T12:37:46.6110157Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\MyCompany.Printing.pdb" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Printing.pdb". 2017-11-22T12:37:46.6120076Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\de\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\de\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6130172Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\es\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\es\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6150139Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\fr\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\fr\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6170152Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\it\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\it\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6180147Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\ja\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ja\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6190140Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\ko\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ko\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6210157Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\pt\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\pt\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6230079Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\ru\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\ru\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6240117Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\zh-CHS\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\zh-CHS\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6260022Z Copying file from "C:\agent\_work\20\s\MasterReference\Code\MyCompany.Common\bin\Release\zh-CHT\Microsoft.ReportViewer.WinForms.resources.dll" to "Source\Code\HorizonDashboard\\Bin\zh-CHT\Microsoft.ReportViewer.WinForms.resources.dll". 2017-11-22T12:37:46.6280124Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\bin\Release\MyCompany.Printing.dll" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Printing.dll". 2017-11-22T12:37:46.6290117Z Copying file from "C:\agent\_work\20\s\Utility\Code\MyCompany.Printing\bin\Release\MyCompany.Printing.pdb" to "Source\Code\HorizonDashboard\\Bin\MyCompany.Printing.pdb". 2017-11-22T12:37:46.6370118Z C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_compiler.exe -v /HorizonDashboard -p Source\Code\HorizonDashboard\ -u -f PrecompiledWeb\HorizonDashboard\ 2017-11-22T12:37:51.6752006Z ##[warning]Source\Code\HorizonDashboard\TreeViewReports.aspx.vb(138,0): Warning BC42324: Using the iteration variable in a lambda expression may have unexpected results. Instead, create a local variable within the loop and assign it the value of the iteration variable. 2017-11-22T12:37:51.6752006Z C:\agent\_work\20\s\Source\Code\HorizonDashboard\TreeViewReports.aspx.vb(138): warning BC42324: Using the iteration variable in a lambda expression may have unexpected results. Instead, create a local variable within the loop and assign it the value of the iteration variable. [C:\agent\_work\20\s\HorizonDashboard.metaproj] 2017-11-22T12:37:52.1572182Z Done Building Project "C:\agent\_work\20\s\HorizonDashboard.metaproj" (default targets). 2017-11-22T12:37:52.1602167Z Done Building Project "C:\agent\_work\20\s\Horizon.sln" (default targets). 2017-11-22T12:37:52.1702198Z 2017-11-22T12:37:52.1702198Z Build succeeded. 2017-11-22T12:37:52.1712201Z 2017-11-22T12:37:52.1752157Z "C:\agent\_work\20\s\Horizon.sln" (default target) (1) -> 2017-11-22T12:37:52.1782189Z "C:\agent\_work\20\s\HorizonDashboard.metaproj" (default target) (2) -> 2017-11-22T12:37:52.1792194Z (Build target) -> 2017-11-22T12:37:52.1792194Z C:\agent\_work\20\s\HorizonDashboard.metaproj : warning MSB3247: Found conflicts between different versions of the same dependent assembly. In Visual Studio, double-click this warning (or select it and press Enter) to fix the conflicts; otherwise, add the following binding redirects to the "runtime" node in the application configuration file: 2017-11-22T12:37:52.1802191Z 2017-11-22T12:37:52.1802191Z 2017-11-22T12:37:52.1812189Z "C:\agent\_work\20\s\Horizon.sln" (default target) (1) -> 2017-11-22T12:37:52.1812189Z "C:\agent\_work\20\s\HorizonDashboard.metaproj" (default target) (2) -> 2017-11-22T12:37:52.1812189Z C:\agent\_work\20\s\Source\Code\HorizonDashboard\TreeViewReports.aspx.vb(138): warning BC42324: Using the iteration variable in a lambda expression may have unexpected results. Instead, create a local variable within the loop and assign it the value of the iteration variable. [C:\agent\_work\20\s\HorizonDashboard.metaproj] 2017-11-22T12:37:52.1812189Z 2017-11-22T12:37:52.1812189Z 2 Warning(s) 2017-11-22T12:37:52.1812189Z 0 Error(s) 2017-11-22T12:37:52.1812189Z 2017-11-22T12:37:52.1812189Z Time Elapsed 00:00:09.27 2017-11-22T12:37:52.2242207Z ##[section]Finishing: Build solution 2017-11-22T12:38:01.4345754Z ##[section]Starting: Publish Artifact 2017-11-22T12:38:01.4345754Z ============================================================================== 2017-11-22T12:38:01.4345754Z Task : Publish Build Artifacts 2017-11-22T12:38:01.4345754Z Description : Publish build artifacts to Visual Studio Team Services/TFS or a file share 2017-11-22T12:38:01.4345754Z Version : 1.124.1 2017-11-22T12:38:01.4345754Z Author : Microsoft Corporation 2017-11-22T12:38:01.4345754Z Help : [More Information](https://go.microsoft.com/fwlink/?LinkID=708390) 2017-11-22T12:38:01.4345754Z ============================================================================== 2017-11-22T12:38:02.3426112Z ##[command]robocopy.exe /E /COPY:DA /NP /R:3 "C:\agent\_work\20\a" "\\tfs-build\Builds\Live\Horizon Dashboard_20171122.1\drop" * 2017-11-22T12:38:02.3426112Z 2017-11-22T12:38:02.3426112Z ------------------------------------------------------------------------------- 2017-11-22T12:38:02.3426112Z ROBOCOPY :: Robust File Copy for Windows 2017-11-22T12:38:02.3436082Z ------------------------------------------------------------------------------- 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z Started : 22 November 2017 12:38:02 2017-11-22T12:38:02.3436082Z Source : C:\agent\_work\20\a\ 2017-11-22T12:38:02.3436082Z Dest : \\tfs-build\Builds\Live\Horizon Dashboard_20171122.1\drop\ 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z Files : * 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z Options : /S /E /DCOPY:DA /COPY:DAT /NP /R:3 /W:30 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z ------------------------------------------------------------------------------ 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z 0 C:\agent\_work\20\a\ 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z ------------------------------------------------------------------------------ 2017-11-22T12:38:02.3436082Z 2017-11-22T12:38:02.3436082Z Total Copied Skipped Mismatch FAILED Extras 2017-11-22T12:38:02.3436082Z Dirs : 1 0 0 0 0 0 2017-11-22T12:38:02.3487067Z Files : 0 0 0 0 0 0 2017-11-22T12:38:02.3496344Z Bytes : 0 0 0 0 0 0 2017-11-22T12:38:02.3496344Z Times : 0:00:00 0:00:00 0:00:00 0:00:00 2017-11-22T12:38:02.3496344Z Ended : 22 November 2017 12:38:02 2017-11-22T12:38:02.3496344Z 2017-11-22T12:38:02.3496344Z ##[debug]robocopy exit code '0' 2017-11-22T12:38:02.3916122Z ##[section]Async Command Start: Associate Artifact 2017-11-22T12:38:02.3916122Z Associated artifact 26828 with build 29739 2017-11-22T12:38:02.3916122Z ##[section]Async Command End: Associate Artifact 2017-11-22T12:38:02.3916122Z ##[section]Finishing: Publish Artifact 2017-11-22T12:38:02.3936125Z ##[section]Starting: Post Job Cleanup 2017-11-22T12:38:02.4046142Z ##[section]Finishing: Post Job Cleanup 2017-11-22T12:38:02.4106128Z ##[section]Finishing: Phase 1
答案 0 :(得分:1)
&#34;网站&#34;项目不同于&#34; Web App&#34;项目。 &#34; Asp.Net(预览)&#34;模板用于Web应用程序项目。
对于&#34;网站&#34;项目,您只需要将项目源文件夹直接部署到您的服务器。所以你只需要设置&#34;发布路径&#34;到&#34; Build.SourcesDirectory
&#34;在&#34;发布神器&#34;步骤
答案 1 :(得分:0)
默认情况下,构建工件位于$(Build.SourcesDirectory)
,因此您应在MSBuild参数中指定输出目录,或添加复制文件任务以将工件从$(Build.SourcesDirectory)
复制到$(build.artifactstagingdirectory)
。详细选项如下:
您可以将MSbuild参数设置为:
/p:OutDir="$(build.artifactstagingdirectory)\\"
或者作为:
/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation=$(build.artifactstagingdirectory)
源文件夹:$(System.DefaultWorkingDirectory)
内容:用户通配符,用于指定需要复制的文件
目标文件夹:$(build.artifactstagingdirectory)
答案 2 :(得分:-1)
在Visual Studio Build步骤的MS Build Arguments中,我传递了以下参数:
/p:SkipInvalidConfigurations=true
/p:DeployOnbuild=True
/p:GenerateProjectSpecificOutputFolder=true
/p:GenerateBuildInfoConfigFile=false
/p:OutDir=$(Build.BinariesDirectory)
/p:UseWPP_CopyWebApplication=true
/p:PipelineDependsOnBuild=false
构建结果最终在$(Build.BinariesDirectory)
。从那里我可以执行复制和发布构建工件步骤(不建议使用)或复制任务和发布构建工件任务。无论哪种方式,它最终都会将结果从$(Build.BinariesDirectory)\ApplicationName\_PublishedWebsites\ApplicationName
文件夹复制到$(build.artifactstagingdirectory)\ApplicationName
文件夹并发布。