hi, i'm using teamcity 5.1.5.. trying to build an MSBuild project with an AfterDeploy target which calls a java function..
i get the following error: 'java' is not recognized as an internal or external command

I've tested the java command on the build server and the agent servers and they all run the command..but it seems it fails when running through teamcity.

any ideas?

i've checked the build agent env vars and they seem correctly setup:

## Environment variables defined in the agent configuration file

 JAVA_HOME C:\Program Files\Java\jdk1.6.0_21 C:\Program Files\Java\jdk1.6.0_21 C:\TeamCity\jre

the only thing i notice is that the java.exe are actually in the bin folders here not the root folder.