How to push my Nuget package to the official gallery having my package at my own server

StackOverflow https://stackoverflow.com/questions/13939625

  •  10-12-2021
  •  | 
  •  

Question

I have a web public folder which I use when I want to share any file so I was thinking on having my nuget package there. I tried to push it using:

nuget push Me.Utility.1.0.nupkg API_KEY -Source http://www.mywebpage.mx/packages

then it asked me for the credentials but none of the ones I put have worked (the credentials are correct). My web folder is not a nuget feed is just a web shared folder. Is not clear to me if the problem is that it should be a nuget feed (something like myget service) or which is the minimum infrastructure that I need to have since this is only one nuget package. I want to host my package at my own server and also I want my package to appear in the official gallery, so in that case should I set up my own nuget feed?
Could you please explain how this should be done?

Was it helpful?

Solution

MyGet.org supports pushing packages upstream, for instance to NuGet.org. Check out this blogpost to know how to do this: http://blog.myget.org/post/2012/03/01/Introducing-MyGet-package-source-proxy-(beta).aspx

OTHER TIPS

The official gallery meaning nuget.org? With nuget.org you can't choose to host your nupkg on an external site, nuget.org has to host it for you. You might be confusing myget.org and nuget.org concepts.

PS: if you use the argument to override 'source' then you are no longer using the official gallery nuget.org. Hence the question title is confusing.

We have a (free) product that may help you. ProGet gives you the ability to host a custom NuGet feed on your own network, and allows you seamlessly connect to an existing feed such as the NuGet.org one with a "connector". If you publish to the official NuGet gallery and enable caching on your private feed in ProGet, anytime you consume your own package from the official NuGet feed it will automatically cache it (and any others) on your network for you.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top