I have custom Nuget repository (\\build\NugetFeed) and also i'm using nuget.org to restore my packages.
For restoring packages I use this command
dotnet restore --source \\build\NugetFeed --source https://api.nuget.org/v3/index.json --verbosity n
But on my build server I get the following error
C:\Program Files\dotnet\sdk\2.2.107\NuGet.targets(114,5): error : The local source 'D:\BuildAgent\_work\5\s\https:\api.nuget.org\v3\index.json' doesn't exist. [D:\BuildAgent\_work\5\s\MyCode.sln]
and no packages from official Nuget is restored. Is there any another config options for using dotnet restore?
Seems like a dotnet cli restore command error,
It fails if you specify the local origin first, but works otherwise
Anyway, you can always use a custom Nuget.config
or even add it to the project itself
this issue seems related