我们运行具有身份验证的公司代理,并且将Hudson作为我们的CI平台。 Hudson可以与外界联系,确定哪些插件需要更新,但是当我们告诉Hudson将更新下载到插件时,会出现以下错误。
java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required ( The ISA Server requires authorization to fulfill the request. Access to the Web Proxy service is denied. )"
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection$6.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.net.www.protocol.http.HttpURLConnection.getChainedException(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown Source)
at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:603)
at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:812)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required ( The ISA Server requires authorization to fulfill the request. Access to the Web Proxy service is denied. )"
at sun.net.www.protocol.http.HttpURLConnection.doTunneling(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(Unknown Source)
at java.net.URLConnection.getHeaderFieldInt(Unknown Source)
at java.net.URLConnection.getContentLength(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getContentLength(Unknown Source)
at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:602)
... 7 more
有谁知道我如何配置Hudson或我们的JRE或需要进行任何配置,以允许Hudson通过GUI更新?当然,我们可以手动下载更新,但是一段时间后会很烦人。
目前,我们已将Hudson作为服务安装在Windows Server 2008上,并且使用Hudson随附的内置服务器来托管它。另外,我已经通过“高级”标签设置了代理配置
最佳答案
两件事要做
1. Pop over into the plugin manager and select advanced, enter the settings in there
2. Set the properties of the JRE http://java.sun.com/javase/6/docs/technotes/guides/net/properties.html
启动hudson时,可以使用-Dproperty.name = some.value语法设置属性。
关于configuration - 如何让Hudson通过代理进行更新,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1975564/