[英]Windows 10 Jenkins Pipeline Failed to connect to repository
I am getting started learning Jenkins and am following this "simple" tutorial found within the Jenkins documentation; 我在开始学习詹金斯和我下面这个詹金斯文档中发现的“简单”的教程; it's a tutorial which goes through how to get a simple java-maven-jenkins setup working locally.
这是一个教程,介绍了如何获取在本地工作的简单java-maven-jenkins设置。 I followed the tutorial instructions carefully and have gotten the needed git repository forked and cloned for myself as well as Jenkins started on my localhost, but I ran into a wall when I reached this part:
我认真地按照教程的说明进行操作,并为自己创建了所需的git存储库,并对其进行了克隆,以及Jenkins在本地主机上启动,但是到了这一部分时,我遇到了麻烦:
Create your Pipeline project in Jenkins where on step 8: 在Jenkins中创建您的Pipeline项目 ,在第8步中:
"In the Repository URL field, specify the directory path of your locally cloned repository above, which is from your user account/home directory on your host machine, mapped to the /home directory of the Jenkins container - ie “在“存储库URL”字段中,指定上面本地克隆的存储库的目录路径,该目录路径来自主机上的用户帐户/主目录,映射到Jenkins容器的/ home目录,即
For macOS - /home/Documents/GitHub/simple-java-maven-app 对于macOS-/ home / Documents / GitHub / simple-java-maven-app
For Linux - /home/GitHub/simple-java-maven-app 对于Linux-/ home / GitHub / simple-java-maven-app
For Windows - /home/Documents/GitHub/simple-java-maven-app" 对于Windows-/ home / Documents / GitHub / simple-java-maven-app“
I am using Windows 10 with GitHub Desktop and made sure that the repository was in the required place following the tutorial, but when I try to put the Repository URL as /home/Documents/GitHub/simple-java-maven-app (as the tutorial is asking to do), I get the following error within Jenkins: 我将Windows 10与GitHub Desktop结合使用,并确保该存储库位于本教程之后的必需位置,但是当我尝试将存储库URL放置为/ home / Documents / GitHub / simple-java-maven-app(作为教程要求这样做),我在Jenkins中收到以下错误:
I tried searching for others with the same problem but could only find something related to solving problems with Unix-systems. 我尝试搜索其他具有相同问题的人,但只能找到与解决Unix系统问题有关的东西。
This question I found has a similar problem encountered, but I was not able to solve this problem on my system, as it focuses on Unix systems as well. 这个问题 ,我发现有遇到过类似的问题,但我没能解决我的系统上这个问题,因为它侧重于Unix系统也是如此。
Another weirdness (to my eyes) was that Jenkins asks for the remote repository URL according to the help button, but the tutorial insists to put the local repository as the URL. (在我看来)另一个怪异的是,詹金斯根据帮助按钮要求提供远程存储库URL,但是本教程坚持将本地存储库作为URL。 As I am very new with Jenkins, it would be much appreciated if someone could enlighten me how to fix this to be able to finish the tutorial.
由于我对Jenkins刚起步,因此如果有人能启发我如何解决此问题以完成本教程,将不胜感激。 Also because I am new with Jenkins, I hope who ever can help can really try to explain the solution in layman terms.
另外,因为我对詹金斯(Jenkins)并不陌生,所以我希望能够提供帮助的人真的可以尝试以外行的方式解释解决方案。
Cheers 干杯
Instead of using %HOMEPATH% in docker run command use c:\\Users\\ for mounting volume. 而不是在docker run命令中使用%HOMEPATH%,而使用c:\\ Users \\来安装卷。 After that docker will ask you permission allow it and enter your password.
之后,泊坞窗将询问您允许的权限并输入密码。 it will work.
它会工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.