Visual Studio Team Services Continuous Integration: NuGet Restore Task Failed

Hussein Salman picture Hussein Salman · Apr 22, 2016 · Viewed 7.3k times · Source

I am using Continuous Integration feature in Team Services (was Visual Studio Online). My build definition targets a specific project in a solution (not the whole solution), which is ClientUI MVC website.

The solution contains three projects:

  1. ClientUI
  2. AdminUI
  3. Client Services

enter image description here

The Build Definition for ClientUI Project:

Repository:

enter image description here

Nuget Installer Step: I have tried different params but not working. enter image description here

Visual Studio Build

enter image description here

Before trying to target the a single project, my build definition was targeting the whole solution with the following parameters:

  1. NuGet Installer -> Path to Solution: **\*.sln
  2. Visual Studio Build -> Solution: **\*.sln ; MSBuild Arguments: /p:outdir=$(build.artifactstagingdirectory)

It was working. However now, it generates this error in the Nugget Restore Task:

Answer

Eddie Chen - MSFT picture Eddie Chen - MSFT · Apr 25, 2016

Try setting "Installation type" to "Install" for "Nuget Installer" task since you are using "packages.config" to install the packages. enter image description here