not all system properties are passed to agent's java properties file

TEAMCITY_BUILD_PROPERTIES_FILE environment variable contains the file name of the java properties file that contains all the properties which are passed to the build (ths 'system.' prefix is removed in these).

In the previous 7.1.5 version I was able to use the MSTest.11.0 property (which was injected into the NAnt properties hashtable by teamcity from this file), but after upgrading to 8.0.2 this is no longer works due to this property (as well as MSTest.10.0) is not listed in this property file.

3 comments
Comment actions Permalink

Also it is unclear to me how to access the agent properties from a build script. Seems some of them are missing.

The documentation lists the available agent properties: http://confluence.jetbrains.com/display/TCD8/Predefined+Build+Parameters#PredefinedBuildParameters-tablePredefinedProperties

However, only a subset of these are available in the TEAMCITY_BUILD_PROPERTIES_FILE.
How to access for example os.name, os.version, user.country, etc. These are missing for me.

Maybe I misinterpret something and these are 'Configuration Parameters' that are never passed to the build unless I pass them explicitly as a new system.myvar=%agent.jvm.os.arch%? Docs is unclear for me.

0
Comment actions Permalink

Note that I can work this around if I specify system.MSTest.11.0=C\:\\path\\to\\mstest.exe in agent properties file on each agent's conf/ directory. This way the param will be available for me without explicitly passing it.

However, I'd like to know why this is skipped in 8.0.2.

0
Comment actions Permalink

I got into the same troubles, neither MSTest.10.0, nor MSTest.11.0 properties are available in my MSBuild scripts after upgrading from 7.1.4 to 8.0.5.

0

Please sign in to leave a comment.