Trigger Releases in Visual Studio Release Management

In my previous post, I showed how you can trigger a release in Visual Studio Release Management from a TeamCity build step.

When Visual Studio Release Management 2013 RTM’ed, it came with customized TFS build templates that made it easy to trigger a release from a TFVC or Git build in TFS. These build templates relied on the ReleaseManagementBuild command line client, so it required the VSRM client being installed on the build server.

Then, with the update train of Visual Studio 2013, new functionality such as vNext deployments, support for Powershell DSC etc was added. Together with this a new REST API was introduced that removes the need for a command line application to trigger a release. However, this REST API _only_ works for vNext deployments, and it will most likely never be implemented for agent based deployments. Basically all new functionality in the release management area only works for vNext deployements, so you should be looking to move in that direction.

Also, in VS 2013 Update 4 support was added for connecting to the Release Management service running in Visual Studio Online. With this option, another way of triggering release was added, in which the Release Management service listens for build completion events in TFS which will kick off a release. It is still possible to use the API however, in cases where you don’t run TFS Build.

 

So, since this is rather confusing at the moment and causes a lot of questions, I decided to summarize the currently available combinations and the options that you have when it comes to triggering a release in VSRM:

 

Source

Release Management

Deployment Type

Options

VSO Build

VSO

vNext

Automatically (through build completed event)

VSO Build

VSO

Agent-Based

N/A

TFS Build

On-Premise (Update 3)

vNext

REST API

TFS Build

On-Premise (Update 3)

Agent-Based

ReleaseBuildTemplate

3rd party/share

VSO

vNext

REST API

3rd party/share

VSO

Agent-Based

N/A

3rd party/share

On-Premise (Update 3)

vNext

REST API

3rd party/share

On-Premise (Update 3)

Agent-Based

ReleaseManagementBuild.exe

Note that some of these combinations are not supported at the moment, those are marked with N/A.

Hope that helps

0 thoughts on “Trigger Releases in Visual Studio Release Management”

  1. Originally posted on: http://geekswithblogs.net/jakob/archive/2015/02/05/trigger-releases-in-visual-studio-release-management.aspx#644386

    With RM update 4 it listens to builds completion, will he trigger release for each build or take the latest one ? the senario is we assume that a release takes time (provisioning configuring maybe even running acceptance tests) in the meanwhile checkins and builds were generated by tfs will, when RM finish the release will it take the latest one or it queues all of them ? and of course hopefully it always takes the latest one.

Leave a Reply

Your email address will not be published.