Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I publish and access nuget packages within Visual Studio Team Services

I started to give Visual Studio Team Services (was Visual Studio Online) a try. I created projects, added some source code and set up some build jobs. Everything works fine so far as long as I use external nuget dependencies.

Now I want to use some of my own libraries as dependencies in my projects. I am not able to do so. I am not able to access the nuget server hosted by Visual Studio Team Services. I simply do not know the address. I set the "Build Defaults" of my library project to "Copy build output to the server". But how could I access it via nuget?

In the past I worked with Team City, set up an additional build step (NuGet Pack) and could easily access "my" nuget server.

So again, how can I access the nuget publishing on Visual Studio Team Services using Visual Studio 2013? Or is it just not possible that way?

like image 704
Staratnight Avatar asked May 04 '14 11:05

Staratnight


3 Answers

The ability to host NuGet packages alongside the code on Visual Studio Online is planned for Q4 2015.

This will allow other kinds of feed as well as NuGet and will let you create secure feeds as well as make them public.

In the meantime, you have to use MyGet or ProGet (or a similar service) to host your feeds. I believe both are available as an on-site install or as a hosted service. It is also possible to have a network share as a feed source if you really want.

In any case, if you are using Visual Studio Online it will be pretty hard to beat the Visual Studio Online package hosting.

Quick Update... this feature is in preview at the moment. There are a few little issues that they'll need to fix before it goes live (the restore step and the publish step are problematic, although there are work-arounds using PowerShell steps for NuGet Package Restore and NuGet Package Publish - the packaging step works fine though).

like image 110
Fenton Avatar answered Nov 20 '22 08:11

Fenton


You can now use Team Services to host a private NuGet feed.

It's available in US, Europe and Australia at this time but it won't just show-up, you need to install it into your Team Services account via the marketplace. It's a thing.

https://marketplace.visualstudio.com/items?itemName=ms.feed

like image 38
Luke Puplett Avatar answered Nov 20 '22 07:11

Luke Puplett


Have you looked at Octopus Deploy? They seem to integrate with Team Services and have an option to publish your build to a nuget feed. The nuget feed can be on your Octopus Deploy server, TeamCity server, local file server, or a MyGet server.

  • VSO and Octopus Deploy integration
  • Nuget server on Octopus Deploy
like image 42
Ebsan Avatar answered Nov 20 '22 07:11

Ebsan