I've been spending hours trying every combination to get git work with TeamCity. I'm working with a team that has their own github instance- firstname.lastname@example.org. When trying to authenticate agains the server, I'm getting this error:
Unable to collect changes: jetbrains.buildServer.vcs.VcsException: Problem collecting changes for 'PROJECTX' : Repository 'email@example.com:jbalfantz/gitprojectname.git': Unable to load identity file: c:\temp\id_rsa.pub (passphrase protected)
I'm able to clone directly from the github server using the ssh key. I've copied it to 5 different places to make sure it's not a permissions issue accessing the id_rsa.pub key.
They key was generated following these instructions: https://help.github.com/articles/generating-ssh-keys (ssh-keygen-t rsa -C "firstname.lastname@example.org").
The TeamCity setup:
Type of VCS: Git
Fetch URL: email@example.com:jbalfantz/gitprojectname.git
Authentication Method: Private Key
User name: (blank)
Private Key Path: c:\temp\id_rsa.pub
I've tried variations of the location of the id_rsa.pub file. I've tried other Authentication methods: 1) Anonymous (not supported by server), 2) Default Private Key (List remote refs failed: org.eclipse.jgit.errors.UnsupportedCredentialItem: ssh://firstname.lastname@example.org:22: Password for email@example.com ), and 3) Password (Test connection failed in Platform Tools :: Deploy-Git. Connection test failed: com.jcraft.jsch.JSchException: Auth fail)
Running out of options. I've seen where users used PuttyGen to generate their key, but it appears that ssh-keygen is the supported key generator.