【问题标题】:Jenkins SCM Sync Configuration Plugin not workingJenkins SCM 同步配置插件不起作用
【发布时间】:2016-05-14 08:51:25
【问题描述】:

我安装了 SCM Sync 配置插件。我创建了存储库来保存詹金斯作业的备份。 在创建的作业中,在书签源代码管理中,我提供了存储库 URL 和凭据。 在工作成功之后,我没有在存储库中看到任何提交。 仅此警报出现在右下角:“SCM 同步状态:2016 年 5 月 11 日星期三 10:53:34 EDT:将文件签入 scm 存储库时出错。” 我在 jenkins 中设置了记录器,就像这里所说的那样:https://wiki.jenkins-ci.org/display/JENKINS/ScmSyncConfig+Troubleshootings 但没有人出现。我使它与步骤中描述的相同:“确保您可以从 Jenkins 访问您的 Scm 存储库”。 我设置了名为“詹金斯进程所有者的 id_rsa w 主目录”的个人/私钥。 我可以编辑/hudson.scm。 :

<hudson.scm.SubversionSCM_-DescriptorImpl plugin="subversion@2.5.7">
  <generation>1</generation>
  <mayHaveLegacyPerJobCredentials>false</mayHaveLegacyPerJobCredentials>
  <workspaceFormat>8</workspaceFormat>
  <validateRemoteUpToVar>false</validateRemoteUpToVar>
  <storeAuthToDisk>false</storeAuthToDisk>
</hudson.scm.SubversionSCM_-DescriptorImpl>

但效果是一样的。构建成功,将文件签入 scm 存储库时出错,没有信息 在记录器中。

这里我将粘贴控制台输出中显示的内容:

Building on master in workspace /home/tomcat/.jenkins/jobs/ScmSyncConfigurationTest/workspace
Cloning the remote Git repository
Cloning repository git@bitbucket.org:~~/jenkinsbackup.git
 > git init /home/tomcat/.jenkins/jobs/ScmSyncConfigurationTest/workspace # timeout=10
Fetching upstream changes from git@bitbucket.org:~~/jenkinsbackup.git
 > git --version # timeout=10
using GIT_SSH to set credentials 
 > git -c core.askpass=true fetch --tags --progress git@bitbucket.org:~~/jenkinsbackup.git +refs/heads/*:refs/remotes/origin/*
 > git config remote.origin.url git@bitbucket.org:~~/jenkinsbackup.git # timeout=10
 > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
 > git config remote.origin.url git@bitbucket.org:~~/jenkinsbackup.git # timeout=10
Fetching upstream changes from git@bitbucket.org:~~/jenkinsbackup.git
using GIT_SSH to set credentials 
 > git -c core.askpass=true fetch --tags --progress git@bitbucket.org:~~/jenkinsbackup.git +refs/heads/*:refs/remotes/origin/*
 > git rev-parse refs/remotes/origin/master^{commit} # timeout=10
 > git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
Checking out Revision 82c782cf29258f58a630d0ce2728bf8c85d4e03d (refs/remotes/origin/master)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 82c782cf29258f58a630d0ce2728bf8c85d4e03d
 > git rev-list 82c782cf29258f58a630d0ce2728bf8c85d4e03d # timeout=10
[workspace] $ /bin/sh -xe /usr/share/apache-tomcat-latest/temp/hudson1626031519696649678.sh
+ echo hello world
hello world
Finished: SUCCESS

如果有什么我跳过了,我会很感激你的努力帮助我提供任何线索。

【问题讨论】:

  • 我也无法让这个插件工作,但最终由于 0.0.9 版本中的错误而停止尝试使用它。一旦你重新启动 jenkins,你的整个 jenkins 站点将只是一个白屏,你必须手动恢复配置来修复。这不是小问题。

标签: git jenkins jenkins-plugins


【解决方案1】:

SCM Sync configuration plugin 的主要错误是作业名称中有空格:issue JENKINS 24686

它刚刚在 0.10.0 版本中得到修复 (released 7 hours ago)

您可以检查新版本是否仍然存在您的特定问题。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-08-16
    • 1970-01-01
    • 2022-06-13
    • 1970-01-01
    • 1970-01-01
    • 2012-04-24
    相关资源
    最近更新 更多