简体   繁体   English

Hudson无法克隆git存储库+ Hudson PORT更改

[英]Hudson failed to clone git repository + Hudson PORT change

Today I started using hudson for continuous integration. 今天,我开始使用hudson进行持续集成。 I installed it on my windows machine and configured everything as described in the book about installation and configuration. 我将其安装在Windows计算机上,并按照有关安装和配置的书中所述配置了所有内容。 I am using its git plugin to fetch from git repository and build. 我正在使用其git插件从git存储库中获取并进行构建。

My 1st problem is the same as this one 我的第一个问题和这个一样

Unable to Run Build on Hudson Using Git 无法使用Git在Hudson上运行构建

The git repository from where i want to clone is a private repository, which uses shh key without paraphrase. 我要从中克隆的git存储库是一个私有存储库,它使用shh键而没有解释。 The above question suggested the solution to remove the paraphrase which in my case does not exists at all. 上面的问题提出了删除在我的情况下根本不存在的复述的解决方案。

I searched and tried some other solutions as well but no success. 我也搜索并尝试了其他解决方案,但没有成功。

Following is the trace log 以下是跟踪日志

Started by user anonymous
Checkout:workspace / C:\Users\UIQBAL\.hudson\jobs\Test\workspace -   hudson.remoting.LocalChannel@14be0c6
Using strategy: Default
Checkout:workspace / C:\Users\UIQBAL\.hudson\jobs\Test\workspace -  hudson.remoting.LocalChannel@14be0c6
Fetching changes from the remote Git repository
Fetching upstream changes from git@vrtbichler11.informatik.tu-muenchen.de:wsc18
ERROR: Problem fetching from origin / origin - could be unavailable. Continuing anyway
hudson.plugins.git.GitException: Error performing command: C:\Program Files   (x86)\SmartGitHg 4.5\git\bin\git.exe fetch -t git@vrtbichler11.informatik.tu-    muenchen.de:wsc18 +refs/heads/*:refs/remotes/origin/*
 null
at hudson.plugins.git.GitAPI.launchCommandIn(GitAPI.java:744)
at hudson.plugins.git.GitAPI.launchCommand(GitAPI.java:706)
at hudson.plugins.git.GitAPI.fetch(GitAPI.java:193)
at hudson.plugins.git.GitAPI.fetch(GitAPI.java:960)
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:1617)
at hudson.plugins.git.GitSCM.access$900(GitSCM.java:107)
at hudson.plugins.git.GitSCM$3.invoke(GitSCM.java:954)
at hudson.plugins.git.GitSCM$3.invoke(GitSCM.java:919)
at hudson.FilePath.act(FilePath.java:791)
at hudson.FilePath.act(FilePath.java:773)
at hudson.plugins.git.GitSCM.gerRevisionToBuild(GitSCM.java:919)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:698)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1515)
at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:521)
at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:428)
at hudson.model.Run.run(Run.java:1390)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:40)
at hudson.model.ResourceController.execute(ResourceController.java:82)
at hudson.model.Executor.run(Executor.java:137)
 Caused by: java.lang.InterruptedException
at java.lang.ProcessImpl.waitFor(ProcessImpl.java:353)
at hudson.Proc$LocalProc.join(Proc.java:222)
at hudson.Launcher$ProcStarter.join(Launcher.java:273)
at hudson.plugins.git.GitAPI.launchCommandIn(GitAPI.java:731)
... 18 more
  ERROR: Could not fetch from any repository
  FATAL: Could not fetch from any repository
  hudson.plugins.git.GitException: Could not fetch from any repository
at hudson.plugins.git.GitSCM$3.invoke(GitSCM.java:961)
at hudson.plugins.git.GitSCM$3.invoke(GitSCM.java:919)
at hudson.FilePath.act(FilePath.java:791)
at hudson.FilePath.act(FilePath.java:773)
at hudson.plugins.git.GitSCM.gerRevisionToBuild(GitSCM.java:919)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:698)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1515)
at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:521)
at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:428)
at hudson.model.Run.run(Run.java:1390)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:40)
at hudson.model.ResourceController.execute(ResourceController.java:82)
at hudson.model.Executor.run(Executor.java:137)  

Is there a way to provide my git repository shh key to hudson ? 有没有办法将我的git仓库shh密钥提供给hudson?

2nd Problem: I also installed hudson on my VM, and it runs on port 8080 but my tomcat is also running on port 8080. I tried to change the port of hudson but no success, For windows it is in hudson.xml but my VM is running on fedora. 第二个问题:我还在我的VM上安装了hudson,它在端口8080上运行,但是我的tomcat也在8080端口上运行。我试图更改hudson的端口,但是没有成功,对于Windows,它位于hudson.xml中,但是我的VM在fedora上运行。

What I tried to change the port is 我试图更改端口是

stop hudson
vi /etc/sysconfig/hudson 
start hudson
check to see on which port hudson is running and it gives httpPort=12398 

 [root@wsc18 bin]# ps -ef| grep hudson | grep Port
 root     22604 22602  0 04:51 ?        00:00:00 runuser -s /bin/bash hudson -c ulimit -S -c 0 >/dev/null 2>&1 ; /usr/bin/java -Djava.awt.headless=true -  DHUDSON_HOME=/var/lib/hudson -jar /usr/lib/hudson/hudson.war -- logfile=/var/log/hudson/hudson.log --daemon --httpPort=12398 --debug=5 -- handlerCountMax=100 --handlerCountMaxIdle=20
 hudson   22607 22604  0 04:51 ?        00:00:00 bash -c ulimit -S -c 0 >/dev/null 2>&1  ; /usr/bin/java -Djava.awt.headless=true -DHUDSON_HOME=/var/lib/hudson -jar  /usr/lib/hudson/hudson.war --logfile=/var/log/hudson/hudson.log --daemon --httpPort=12398 - -debug=5 --handlerCountMax=100 --handlerCountMaxIdle=20
 hudson   22608 22607 14 04:51 ?        00:00:07 /usr/bin/java -Djava.awt.headless=true   -DHUDSON_HOME=/var/lib/hudson -jar /usr/lib/hudson/hudson.war -- logfile=/var/log/hudson/hudson.log --daemon --httpPort=12398 --debug=5 -- handlerCountMax=100 --handlerCountMaxIdle=20

when I open it on vmlocalhost:12398 it does not respond. 当我在vmlocalhost:12398上打开它时,它没有响应。

Any help will be highly appreciated. 任何帮助将不胜感激。

Thanks 谢谢

通过在iptables中添加端口12398的条目来解决第二个问题

I am able to solve your 1st Problem by adding windows Environment Variable. 我可以通过添加Windows环境变量来解决您的第一个问题。

Name: HOME
Value: $USERPROFILE

for more info go this URL http://element34.ca/blog/jenkins-remote-windows-nodes-and-private-github-repos 有关更多信息,请访问此URL http://element34.ca/blog/jenkins-remote-windows-nodes-and-private-github-repos

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

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