开发者

TeamCity build labeling failing intermittently on a git repository

开发者 https://www.devze.com 2023-03-08 12:48 出处:网络
My build is running on Windows Server 2003, TeamCity 6.0.3. The git repository is stored on the same server and is accessed via cygwin\'s sshd and gitd. My vcs configuration in TeamCity is as follows:

My build is running on Windows Server 2003, TeamCity 6.0.3. The git repository is stored on the same server and is accessed via cygwin's sshd and gitd. My vcs configuration in TeamCity is as follows:

Fetch URL: git://server/Repo

Push URL: ssh://server/~/Repo

Authentication settings

Authentication Method: Password

User name: TeamCitySC (this is a local account set up specifically for labeling)

Password: * * * * * *

for each user there is a symlink in their home path to the Repository hence the ~/Repo path. Labeling worked just fine for about a 100 builds, recently it has periodically started to complain with the following message:

Labeling failed for root 'git root' org.eclipse.jgit.api.errors.JGitInternalExcepti开发者_运维问答on: Updating the ref refs/tags/build-108 to Tag[03e70a74b39c1393f5ce684424194210513b4d48]={ object 0f6101df222f5370a17f5ce1c97eb2348d64970c type commit tag build-108 tagger PersonIdent[SYSTEM, SYSTEM@server, Thu May 26 16:16:07 2011 -0600] } failed. ReturnCode from RefUpdate.update() was REJECTED at org.eclipse.jgit.api.TagCommand.call(TagCommand.java:159) at jetbrains.buildServer.buildTriggers.vcs.git.GitVcsSupport.label(GitVcsSupport.java:1334) at jetbrains.buildServer.vcs.impl.VcsLabeler.setLabel(VcsLabeler.java:80) at jetbrains.buildServer.vcs.impl.VcsLabeler.setLabel(VcsLabeler.java:1) at jetbrains.buildServer.serverSide.impl.FinishedBuildImpl.setLabel(FinishedBuildImpl.java:10) at jetbrains.buildServer.serverSide.impl.auth.SecuredBuildFactory$SecuredFinishedBuildImpl.setLabel(SecuredBuildFactory.java:3) at jetbrains.buildServer.controllers.SetLabelAction.doProcess(SetLabelAction.java:11) at etc...

It continues to fail even when I manually try to label the build via TeamCity (i.e. 'Label this build sources' link in the Changes tab for a given build).


From the ReturnCode REJECTED in the error message it seems like your repository already has tag refs/tags/build-108 and TeamCity does not force rewrite existing tag.


Upgrade to TeamCity 6.5. It was released yesterday. We have had quite a lot of trouble with the DVCS functionality in 6.0.x. 6.5 is a great improvement. If the upgrade does not solve your issue, reply here. It made a lot of headaches for us go away. I'm not sure, but they may have dropped jgit. Seems that jgit has a lot of functionality missing and TeamCity has to work around those in the version you are using. Submodule support is one such feature.

I would also stay away from cygwin and go for the latest msysgit on the server. Cygwin also proved to be much more troublesome than msysgit.

Hope this helps.

0

精彩评论

暂无评论...
验证码 换一张
取 消