I followed the instructions on Hosting Your Own NuGet Feeds:
NuGet.Server
package~/Packages
as the packagesPath
in Web.configNuGet.exe
IUSR
and IIS_IUSRS
users and groupsnuget setApiKey ABC123 -Source http://localhost/NuGet
from the command linenuget push Foo.Bar.dll.nupkg -Source http://localhost/NuGet
The push to the NuGet server succeeded. I can view the folder in Windows Explorer and see the .nupkg file.
When I go to http://localhost/NuGet/nuget/Packages
I get an RSS feed showing the package I just pushed.
When I go to http://localhost/NuGet/nuget/
I get an empty list of packages:
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<service xml:base="http://localhost/NuGet/nuget/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:app="http://www.w3.org/2007/app" xmlns="http://www.w3.org/2007/app">
<workspace>
<atom:title>Default</atom:title>
<collection href="Packages">
<atom:title>Packages</atom:title>
</collection>
</workspace>
</service>
After configuring NuGet in Visual Studio to include http://localhost/NuGet
as one of the package sources, I can't install the package I just pushed either.
This is all running on:
Why does the NuGet package show up in the RSS feed (/NuGet/nuget/Packages
), but not through /NuGet/nuget
?
Because /NuGet/nuget/Packages
is the URL where packages are listed (it just happens to be in RSS format because that was the original implementation decision), and /NuGet/nuget
is the API endpoint used for package operations such as pushing, deleting, etc.
The XML you've posted isn't an empty list of packages, it's more of a service descriptor. An empty list of packages would be the result found at: /NuGet/nuget/Packages()?$filter=1 eq 2