Friday, 22 June 2018

Using NuGet Packages as VSTS Release Artifact Source

If you are used to deploy your solutions with Octopus deploy which a re built with VSTS/TFS, you are used to package your build output as a NuGet package and use it in Octopus. Now you can use the NuGet packages with VSTS release management as well for deployment. For this you have to have the package management feature in VSTS enabled. As VSTS builds and their artifacts are discarded in a configured time period and the maximum time and  number of builds is limited, keeping artifacts as NuGet packages would be useful you to keep your deployed artifacts for a longer period. Let’s explore how to use NuGet packages for deployment in VSTS release management.


You have to create a package feed as the first step.image

You can set the package feed visibility and enable use of public packages via this feed.image


Once you have the package feed setup you can use NuGet task in your build with a push command to push your package built in the build to the internal package feed.image

Then in your release definition for artifacts you can expand artifact types as shown below.image

This will give you few more artifact types including packages. Select the package feed and your package. then set the version to latest or to a preferred one.image

You have the option to even set continuous deployment trigger for new package version availability.image

The package content will be automatically downloaded , extracted and will be available for you similar to a normal artifact drop contents.

No comments:

Popular Posts