我在我的Mercurial项目中添加了SVN项目作为subrepository(遵循this说明),现在TeamCity无法构建Mercurial项目。我得到以下错误:添加SVN子文件到Mercurial后发生TeamCity错误
[Updating sources] Failed to build patch for build #???, VCS root: "mercurial: https://myrepo" {instance id=41, parent internal id=22, parent id=mercurial_repo_id, description: "mercurial: https://myrepo"}, due to error: Cannot build patch: ClientAbortException: java.io.IOException
[Updating sources] Problem while loading patch data stream: Failed to obtain stream from server. Server status: 504 (Gateway Time-out)
Problem while loading patch data stream: Failed to obtain stream from server. Server status: 504 (Gateway Time-out)
java.io.IOException: Failed to obtain stream from server. Server status: 504 (Gateway Time-out)
当我在本地克隆回购,一切都很好,但TeamCity的并不见subrepo并且在变化曲线没有subrepo。我试图添加不同的构建步骤,但它没有帮助。我也试过在TeamCity的改变VCS结账模式代理结账,但有另一个错误是由于自签名sertificates:
Failed to perform checkout on agent: 'hg --config ui.interactive=False clone -U --uncompressed https://...' command failed.
stderr: abort: could not find web.cacerts: /etc/ssl/ca-bundle.pem
然而,结账方式不应该是因为这样的问题,错误的原因已在TeamCity的8个版本中解决(我们使用8.0.6)。
我应该如何配置TeamCity与Mercurial repo内的SVN subrepo一起使用?
谢谢。
UPD:
我终于找到了答案:我虽然需要同时执行对代理结算(添加证书或迫使其信任所有),以修正错误,问题解决了!
SVN回购也被添加到TeamCity,所以TeamCity具有验证信息。这不够吗?如果不是,该文件在哪里?不幸的是,我对TeamCity的管理不太好。 – Lia
这里的窍门是TC没有检出SVN回购,HG客户端是,它不能访问TC。 –
另一种方法是跳过子报表并直接将SVN回购添加到teamcity项目。这可能会失去hg subs具有的“修复特定版本”功能。 –