2014-11-14 29 views
11

我正在尝试配置我的Jenkins作业以连接到Altassian存储。 Jenkins使用git pluginJenkins连接到存储时出错

这里下的源代码管理作业配置详情 - 选择的git:

库网址:https://lab.xyz.com/stash/scm/projects/sandbox.git

凭据:jenkinuser /密码(詹金斯配置的全局信用凭证中定义)

我得到以下错误:

Failed to connect to repository: 
Could not init C:\Windows\TEMP\hudson1141847846411984817tmp 

(tmp名称不断变化)。

感谢任何帮助。谢谢。

+0

这可能是您的本地计算机写入TEMP目录的权限问题。 – Rog 2014-11-16 23:27:19

+0

我们不得不降级到git插件版本1.5.0和git客户端插件版本1.0.7,它工作。 – parram 2014-11-18 23:05:16

+0

Red Hat出现类似错误。通过在Jenkins服务器上安装'git'来修复它: 'yum install -y git' – 2016-07-15 09:10:17

回答

12

我迟到知道它的一点点,但这个工作对我来说:

Check if you have install git on the Jenkins server, and check if you have set the git executable path in the Jenkins configuration

More specifically go to 'Manage Jenkins' -> 'Global Tool Configuration' and check the 'Path to Git executable' field.

来源:https://serverfault.com/a/669487/212634

2

在全球工具配置,在那里你“set”GIT位置: C:/ Program Files(x86)/Git/bin/git.exe。不要忘记包含'.exe'扩展名。 它适用于Windows。