简体   繁体   中英

Continuous Integration on VSTS - Build Definition: No Files - System.AggregateException

I am using Visual Studio Team Services. I created a Simple ASP.NET website and created my Build definition which contains default settings.

在此处输入图片说明

After committing changes, the build is triggered using CI. The " Build Solution " Step works fine, however no files are found in the Copy Files Step:

在此处输入图片说明

I have created the same build definition for a simple console app, and the build and release are working.

When Creating a release from this build, it fails to deploy (i guess because no files are found in (Build process)) and gives the following error:

在此处输入图片说明

When you build Asp.Net project with a default VSBuild definition, the folder bin\\$(BuildConfiguration)\\ does not exist. So "Copy Files" task cannot find any files with the default settings. A simple way to fix your issue is add /p:outdir=$(build.artifactstagingdirectory) in "MSBuild Arguments" for VSBuild task as following:

将自定义参数添加到MsBuild

And you can also remove "Copy Files" task since "Publish Build Artifacts" task publishes the files in $(build.artifactstagingdirectory) folder by default and you have set the build output to that folder with the argument added in VSBuild task.

Update: You can add a "Copy Files" task with the following settings to copy "roslyn" folder to "bin" folder: 在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM