Using Perforce and ANT:
When attempting to call p4 tasks within our own ANT build scripts and utilizing the 'Do not check out files automatically' option of VCS checkout mode, I am continually running into the problem where the P4 login information is not being recognized.
I have set the environment variables through TeamCity:
The error message received is:
error: Perforce password (P4PASSWD) invalid or unset.
Problem exec'ing P4 command: error: Perforce password (P4PASSWD) invalid or unset.
We are using ticket-based authentication on the Perforce server, and this is the same error message received through the VCS Root screen if we do not check the 'Use ticket-based authentication' checkbox.
One way we've gotten around the problem is to call a remote task (telnet or psexec) to establish a session into the build agent and then it will recognize our login variables.
Any ideas or tips to get around this problem?