1

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?

gab
  • 325
  • 1
  • 12

3 Answers3

2

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

Xavier Decoster
  • 14,580
  • 5
  • 35
  • 46
  • Hi Xavier, thanks for answering... my idea is having my nuget packages at my own server, I wouldn't like to have them at any other. And the one important thing is that although I want my packages in my server I want them to be "listed" in the official gallery publicly available. I understood that it is not possible, or is it? – gab Jan 25 '13 at 16:44
  • That's indeed not possible: they're two distinct package repositories, and the NuGet.org Gallery is a public one. Having them on your own (private) server or anywhere else is basically the way to go: a second repository. But you'll need to push some packages from one to the other (to NuGet.org in this case) in order to have some of those available there (on NuGet.org). Or you'd need to aggregate feeds, but you don't control NuGet.org (that's why I referred to MyGet 'cause those scenarios are supported on your own feeds). Hth! Cheers – Xavier Decoster Jan 25 '13 at 20:30
1

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.

Tim Lovell-Smith
  • 15,310
  • 14
  • 76
  • 93
  • 1
    Tim: You understood my question perfectly. I wanted to host my nupkg at my own server but wasn't sure if Nuget has the ability to make a redirection of a package request to any other server but nuget.org (having my nupkg at a external site). So by your answer I'm afraid it is not possible. Althoug it could a nice feature to have I think. – gab Dec 18 '12 at 21:43
1

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.

Tod Hoven
  • 466
  • 2
  • 8