【发布时间】:2016-05-13 16:49:07
【问题描述】:
朋友们,我在 Jenkins 控制台中不断收到以下错误。
"Failed to connect to repository : Command "git -c core.askpass=true ls-remote -h ssh://yyyyyyyy@gerrit.xxxxxxxx.com:29418/mobile HEAD" returned status code 128:
stdout:
stderr: Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists."
尝试了网络上的所有选项。没有任何效果。 在这里感谢您的帮助
在此处填写日志
Building in workspace /Users/Shared/Jenkins/GIT
Cloning the remote Git repository
Cloning repository ssh://yyyyy@gerrit.xxxxxxxx.com:29418/mobile
> git init /Users/Shared/Jenkins/GIT # timeout=10
Fetching upstream changes from ssh://yyyyy@gerrit.xxxxxxxx.com:29418/mobile
> git --version # timeout=10
> git -c core.askpass=true fetch --tags --progress ssh://yyyyyyy@gerrit.xxxxxxxxx.com:29418/mobile +refs/heads/*:refs/remotes/origin/*
ERROR: Error cloning remote repo 'origin'
hudson.plugins.git.GitException: Command "git -c core.askpass=true fetch --tags --progress ssh://yyyyyy@gerrit.xxxxxxxxx.com:29418/mobile +refs/heads/*:refs/remotes/origin/*" returned status code 128:
stdout:
stderr: Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
谢谢, 马达夫
【问题讨论】:
-
我确实创建了 .ssh 文件夹,并且能够通过命令提示符(终端)连接到 GIT。我使用 OS X 顺便说一句
-
您是否可以在没有 jenkins 的情况下使用 ssh 在本地系统上克隆 repo?
-
当然。确实如此。但有时我确实必须运行此命令 /n ssh-add .ssh/id_rsa /n 才能使克隆命令起作用 只有通过 Jenkins 的问题