0

我正在尝试使用 VSTS 在 AWS/AZure 中部署一个 Web 应用程序,因为我有 .sln soultion 文件要构建。MS 构建成功,但即使我找不到它,它也不会生成任何工件。我不知道成功构建后要部署哪个文件。以下是构建生成的日志:

2018-02-23T06:14:56.6241643Z ##[section]开始:构建解决方案**/*.sln 2018-02-23T06:14:56.6245894Z ============== ==================================================== ============= 2018-02-23T06:14:56.6246019Z 任务:MSBuild 2018-02-23T06:14:56.6246112Z 描述:使用 MSBuild 2018-02-23T06:14:56.6246202 构建Z 版本:1.120.0 2018-02-23T06:14:56.6246308Z 作者:Microsoft Corporation 2018-02-23T06:14:56.6246426Z 帮助:更多信息 3437875Z 项目“D:\a\1\s\Laan.SolutionConverter.sln”(1)正在节点 1(默认目标)。2018-02-23T06:15:03.3438402Z 恢复包:2018-02-23T06:15:03.3438811Z "D:\a\1\s.nuget\NuGet.exe" 安装 "D:\a\1\s\Laan .SolutionConverter\packages.config" -source "" -NonInteractive -RequireConsent -solutionDir "D:\a\1\s\ " 2018-02-23T06:15:06.5368000Z 正在恢复 NuGet 包... 2018-02-23T06: 15:06.5368544Z 要防止 NuGet 在构建期间下载包,请打开 Visual Studio 选项对话框,单击包管理器节点并取消选中“允许 NuGet 下载丢失的包”。2018-02-23T06:15:06.9195161Z packages.config 中列出的所有包都已安装。2018-02-23T06:15:06.9965845Z PrepareForBuild: 2018-02-23T06:15:06.9966207Z 创建目录“bin\Debug\”。2018-02-23T06:15:06.9970357Z 创建目录“obj\Debug\”。2018-02-23T06:15:08.7989740Z CoreCompile: 2018-02-23T06:15:08.7990805ZC:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn\csc.exe / noconfig /nowarn:1701,1702 /nostdlib+ /platform:anycpu32bitpreferred /errorreport:prompt /warn:4 /define:DEBUG;TRACE /highentropyva+ /reference:D:\a\1\s\packages\CommandLineParser.1.9.71\lib \net45\CommandLine.dll /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.5\Microsoft.CSharp.dll" /reference:"C:\Program Files (x86) \Reference Assemblies\Microsoft\Framework.NETFramework\v4.5\mscorlib.dll" /reference:"C: 2018-02-23T06:15:25.0246192Z 将文件从“obj\Debug\Laan.SolutionConverter.exe”复制到“bin\Debug\Laan.SolutionConverter.exe”。2018-02-23T06:15:25.0250947Z Laan.SolutionConverter -> D:\a\1\s\Laan.SolutionConverter\bin\Debug\Laan.SolutionConverter.exe 2018-02-23T06:15:25.0253057Z 从复制文件“obj\Debug\Laan.SolutionConverter.pdb”到“bin\Debug\Laan.SolutionConverter.pdb”。2018-02-23T06:15:25.0345637Z 完成构建项目“D:\a\1\s\Laan.SolutionConverter\Laan.SolutionConverter.csproj”(默认目标)。2018-02-23T06:15:25.0355240Z 完成构建项目“D:\a\1\s\Laan.SolutionConverter.sln”(默认目标)。2018-02-23T06:15:25.0372793Z 2018-02-23T06:15:25.0372977Z 构建成功。2018-02-23T06:15:25.0375964Z 0 警告 2018-02-23T06:15:25。

阅读这些日志后,谁能告诉我应该选择部署哪个文件?

4

1 回答 1

0

根据日志:

/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation="D:\a\1\a\"

所以,它应该生成 web 部署包到 artifact 文件夹(D:\a\1\a),如果它是一个 web 应用程序,你可以添加一个Publish Build Artifacts任务来发布这些文件(发布路径$(build.artifactstagingdirectory):)

于 2018-02-26T03:09:01.110 回答