Tokenization for DSC

Update!  This resources has been officially release by Microsoft here

http://tinyurl.com/xReleaseManagement

Update 3 of Release Management introduced Desired State Configuration (DSC) as a deployment option in addition to the deployer based solution.  With DSC we can utilized the Local Configuration Manager (LCM) already installed on many Microsoft operating systems to deploy our applications without the need to install prerequisites.

 However, I noticed after playing with it for a while that there was no mechanism to tokenize files for transformation. This is a requirement for applications that store configuration information in web.config or app.config files.  This data needs to be updated as the code is promoted from one environment to the next.

I set out to fill this gap by writing a custom resource to transform the files as we can with the deployer based option of Release Management.  Attached to this post is a zip file that contains custom Windows PowerShell Cmdlets, custom DSC Resource and a sample configuration that shows how to use them.

The xReleaseManagement folder contains the implementation of the Trackyon_xTokenize resource to be used in your configurations. This resource requires the Write-Token and Test-Token Cmdlets provided in the Trackyon.PowerShell.ReleaseManagement.Module module also in the attached zip.

Finally in the zip file are to ps1 files with a sample configuration and start-dscconfiguration calls.

All of the Cmdlets, resources and tools are provided AS IS, and are not supported through any support program or service.

xReleaseManagement.zip (15.90 kb)

Comments are closed