TeamCity setup to use Mercurial with ssh + authentication key + passphrase?

I've been trying to see if we can use TeamCity for continuous integration at our company, but have been having problem getting it to work for our setup.

We want to use a distributed source repository system, thus Mercurial, where team members can access the Hg server repos, as well as each other's repos, through ssh with public+private authentication keys, and the keys are encrypted (need a passphrase).
On each of our MS-Windows PC/session we run the PuTTY Pageant to cache our private key and enter the passphrase just once.
So that our Mercurial repo accesses, ie "hg pull ssh://hg@server/repo", will just work.

However, using TeamCity, in the VCS Root setting, the above hg access via ssh will not work, just hang.
Clicking the "Test connection" button in VCS Root setup will just hang/wait forever.

The only way I can get TeamCity to work is if I:
-  run TeamCity Server and Build Agent services under user account,
-  and create the Mercurial.ini and set the ssh = plink user.ppk
-  and remove the private key user.ppk encryption (do not use passphrase).
However, our system policy requires having the passphrase.

I've been searching the web, but have not found any answer yet.
There is one guy who wrote about using PSTools' PsExec (in addition to the above),
but it didn't work for me (I could not login to the server, direct login prohibited).

So, is it possible?
What is the magic TeamCity setup to make it work with key passphrase?

1 comment
Comment actions Permalink

Hi Paulus,

Passphrase is not supported for Mercurial in TeamCity. Please create new feature request in out tracker.
As workaround you can probably try solution suggested on stackoverflow.


Please sign in to leave a comment.