【发布时间】:2010-09-20 19:02:34
【问题描述】:
我让哈德森启动并运行。安装了 git 插件。创建新作业,输入 git 存储库 URL,保存并点击“立即构建”。
它只是冻结。当我取消构建时,这就是我得到的:
由匿名用户发起
结帐:工作区/C:\Users\taboo_user.TABOO.hudson\jobs\Interreg\workspace - hudson.remoting.LocalChannel@94aa42 使用策略:默认
结帐:workspace / C:\Users\taboo_user.TABOO.hudson\jobs\Interreg\workspace - hudson.remoting.LocalChannel@94aa42
已创建 GitAPI
克隆远程 Git 存储库
克隆存储库来源
$ "C:\Program Files\Git\bin\git.exe" clone -o origin git@subversion.alise.lv:interreg.git C:\Users\taboo_user.TABOO.hudson\jobs\Interreg\workspace 错误:克隆远程 repo 'origin' 时出错:无法克隆 git@subversion.alise.lv:interreg.git 错误:原因:执行 C:\Program Files\Git\bin\git.exe clone -o origin git@subversion.alise.lv:interreg.git C:\Users\taboo_user.TABOO.hudson\jobs\Interreg\workspace 时出错
空
尝试下一个存储库
错误:无法克隆存储库
致命:无法克隆
我现在用谷歌搜索了大约 2 个小时,没有结果。
Windows 事件查看器为空。
尝试为 hudson windows 服务设置特定用户,该用户具有正确的 ssh 密钥、已知主机,并且能够从命令行 repo 进行 git clone 无问题。
尝试使用 %HOME% 变量参数化 hudson 构建。
尝试将 c:/program files/git/bin 文件夹添加到 PATH 环境变量。
试图明确告诉 hudson 它应该使用c:/program files/git/bin/git.exe。
有关此错误消息的信息很多,但到目前为止没有任何帮助。没有任何想法了。
有什么帮助吗?
回显 $USERNAME
回声 $HOMEPATH
回声 $HOME
返回
[工作区] $ sh -xe C:\Users...
+ 回声禁忌用户
禁忌用户
+ 回声 '\'
\
+回声
用户名肯定是正确的。
【问题讨论】:
-
如果 Hudson 作业打开一个 shell,你需要回显
$USERNAME(不是%USERNAME%)、$PATH(不是%PATH%),...等等。 -
@VonC 看起来像是 $HOME 变量的问题。将
.ssh目录复制到c:/,它终于可以工作了。我想知道为什么我以前不能设置它。有点尝试过。 -
@Anis L.:奇怪,你可以定义 HOME 而不是保留默认值 '/'。
标签: git windows-server-2008 hudson