1

How can I set an environmental variable on a VSO Hosted Build Controller at build time? An ideal solution would be using MSBuild arguments.

Scenario (not necessary to know): I am trying to get an Orleans based Azure Hosted Cloud Service to build and deploy using a VSO Hosted Build Controller. Currently I am hosting my own build controller using TFS however we would like to use the VSO hosted build controller. In order for this to work I have to set the Orleans Environmental Variable to a path within my project on the VSO Hosted Build Controller at build time. We are using a continuous deployment model.

jessehouwing
  • 106,458
  • 22
  • 256
  • 341
beverts312
  • 65
  • 1
  • 9

1 Answers1

1

The MSBuild Arg is

/p: EnvVarName = PathAsAString

It can be the full path(p:OrleansSDK="C:\a\scr\Main\Lib") or the relative path(/p:OrleansSDK="..\..\Lib"), depending on the build process template it might be able to include existing variables (p:OrleansSDK="$(SourcesDir)\Lib").

beverts312
  • 65
  • 1
  • 9