4

I have a team that is working on a Windows service project and need to have environment specific configurations set in their *.exe.config file. They have set up their transformations to leave behind a token if the build is made with the release configuration.

Now I need to create a release definition using the new integration in the release hub through the Web access; I have come across multiple solutions based on the server/client solution Microsoft used previously for their release management but have found no analogue in the tfs 2015 web access.

So, is there an out of the box task to replace tokens on the services configuration file? Or do I need to create a powershell script capable of said functionality, copy it to the target server and then run the replace manually? I'm working as a deploy manager and thus only have access to agents and the tfs server through the website access.

Harshil Lodhi
  • 7,274
  • 1
  • 33
  • 42

2 Answers2

4

I'm going down the PowerShell DSC route for everything - not only configuring the server but then also for deploying the bits (previously copied to a local temp location using a Windows Machine File Copy task) but also for token replacement using xReleaseManagement which works very well indeed.

I'm a week away from publishing a blog about how do use DSC with RM but see here for a DSC precursor to this post and here for the broad details of the road I'm going down.

Graham Smith
  • 517
  • 2
  • 10
  • This would be my recommendation as well -- replace tokens as part of the deployment as opposed to as part of the release. – Daniel Mann Apr 19 '16 at 13:52
  • Thanks @Graham I'm definitely going to need exactly this for the web deployment we will be doing later on, I'll read over the blog and manual to see how I can implement it for the windows service. I know a lot of my problems stem from my lack of access to the tfs server and other servers. – Carlos Emilio Medina Bañuelos Apr 19 '16 at 21:33
  • @carlos-emilio-medina-bañuelos See [here](http://pleasereleaseme.net/continuous-delivery-tfs-vsts-server-configuration-application-deployment-release-management) for my blog post on how to use the web-based Release Management tooling in TFS / VSTS. – Graham Smith May 05 '16 at 06:37
3

The Tokenizer task is not available out of the box in TFS 2015.2. TFS 2015 supports installing extensions and you can install the Tokenizer task from the marketplace.

It comes as a part of Release Management Utility tasks

  1. Download the vsix package.
  2. While downloading it will show you the instruction on how to install.

If you come across any issues, you can report it on our GitHub page

Harshil Lodhi
  • 7,274
  • 1
  • 33
  • 42