Abisek S
Abisek S

Reputation: 55

Environment variable to get the build output path in VS TFS 2015 integrated Release

I am using Visual Studio Team Foundation Server 2015 with Update 1. With this, Microsoft has provided a 'Release' option to deploy applications after successful build. This doesn't require a "Release Management" tool.

There are several pre-defined tasks available in this Integrated Release to copy files to deployment servers. But what I wanted is to create a custom powershell script to copy files from the build output folder(a network path) to my deployment servers(Dev, test, etc). Add Powershell

This requires the help of Environment Variables to find the build output. I have previously gone through the below link for list of variables, https://msdn.microsoft.com/Library/vs/alm/Release/author-release-definition/understanding-tasks#predefvariables

Please help me to identify the Environment variable that gives me the build output path(Not Agent path) specific to my release.
I already checked

[SYSTEM_DEFAULTWORKINGDIRECTORY] --> [C:\agentx\_work\0d0415c0f]

[AGENT_RELEASEDIRECTORY] --> [C:\agentx\_work\0d0415c0f]  

which gives us the path in agent server and not the build output path.
What I require is an env variable to get me \\\Network\devops\Test\Builds\TestApp\20160122.10

My build is configured to copy build output files to a network path.

Upvotes: 0

Views: 829

Answers (1)

Cece Dong - MSFT
Cece Dong - MSFT

Reputation: 31003

You are looking for the location of the drop's environment variable. Check TF_BUILD environment variable TF_BUILD_DROPLOCATION.

Upvotes: 0

Related Questions