简体   繁体   English

在jenkins中配置git存储库

[英]configure git repository in jenkins

I'm trying to configure the repository: https://github.com/javpaw/game-of-life 我正在尝试配置存储库: https//github.com/javpaw/game-of-life

into a job in jenkins using git plugin, but when I put the address of the repository: git@github.com:javpaw/game-of-life.git 使用git插件进入jenkins的工作,但是当我输入存储库的地址时:git@github.com:javpaw / game-of-life.git

Source Code Management -> git -> repository Url I got this error: 源代码管理 - > git - > repository Url我收到此错误:

Failed to connect to repository : Command "/usr/bin/git ls-remote -h git@github.com:javpaw/game-of-life.git HEAD" returned status code 128: stdout: stderr: No protocol specified No protocol specified 无法连接到存储库:命令“/ usr / bin / git ls-remote -h git@github.com:javpaw / game-of-life.git HEAD”返回状态码128:stdout:stderr:未指定协议无协议规定

(ssh-askpass:18881): Gtk-WARNING **: cannot open display: :0.0 Host key verification failed. (ssh-askpass:18881):Gtk-WARNING **:无法打开显示:: 0.0主机密钥验证失败。 fatal: The remote end hung up unexpectedly 致命:远程端意外挂断

I found this question here in github: Why Git fail to connect to local repository with Jenkins (bad config file)? 我在github中找到了这个问题: 为什么Git无法使用Jenkins连接到本地存储库(错误的配置文件)?

but was not useful because I'm using Ubuntu 12.04 但是没用,因为我使用的是Ubuntu 12.04

How can I solve this issue? 我该如何解决这个问题?

thanks. 谢谢。

Try using a complete url, with https rather than ssh: 尝试使用完整的网址,使用https而不是ssh:

https://github.com/javpaw/game-of-life

You can also try the read-only address: 您还可以尝试只读地址:

git://github.com/javpaw/game-of-life.git

But in both case, the important part is that you specify the protocol ( https:// or git:// ) 但在这两种情况下,重要的是你指定协议( https://git://

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM