在 Jenkins 上通过 Java Web Start 启动从代理的问题 [英] Problems launching the slave agent via Java Web Start on Jenkins

查看:38
本文介绍了在 Jenkins 上通过 Java Web Start 启动从代理的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们最近将 Jenkins 升级到最新版本.

We have recently upgraded Jenkins to the latest verion.

从那以后,我每次尝试启动时都无法通过命令行通过 Java WebStart 启动从站,我收到无法启动应用程序"错误

and since then ive not been able to launch the slaves via Java WebStart through the command line everytime I try to launch it I get "Unable to Launch the application" error

在详细信息面板中使用这个

with this in the details panel

CouldNotLoadArgumentException[ Could not load file/URL specified: http://MyServer:8080/computer/Slave1/slave-agent.jnlp]
    at com.sun.javaws.Main.launchApp(Unknown Source)
    at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
    at com.sun.javaws.Main.access$000(Unknown Source)
    at com.sun.javaws.Main$1.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)

当尝试浏览到 Jenkins 站点并从那里使用它时,它可以工作,但是如果您然后重新启动该框,则启动时的命令行将无法完成工作.

When try browsing to the Jenkins site and lunching it from there IT WORKS however if you then restart the box then the command line on the start up fails to do the job.

这是我试图从奴隶运行的命令

This is the command I am trying to run from the slave

cd "C:\Program Files (x86)\Java\jre7\bin"
javaws http://MyServer:8080/computer/Slave1/slave-agent.jnlp

问题是这曾经有效.我也尝试更新到最新版本的 Java,但没有成功,

The problem is that this used to work. I have also tried updating to the latest version of Java but no luck,

有人知道吗?

推荐答案

据说,这种新行为主要是由于 Jenkins 论坛上的帖子,是由于修复了一个安全问题:https://wiki.jenkins-ci.org/display/SECURITY/Jenkins+Security+Advisory+2013-01-04

Supposedly, due in most part to posts on the Jenkins forums, this new behavior is due to a fix for a security issue: https://wiki.jenkins-ci.org/display/SECURITY/Jenkins+Security+Advisory+2013-01-04

似乎有两种解决方案:

  1. 下载 JNLP 文件(通过浏览器、wget、curl 等),然后在本地运行 - 可能需要额外的参数.
  2. 转到管理 Jenkins -> 配置全局安全性,在基于项目的矩阵授权策略下,为用户匿名"启用从"部分中的连接".如果有人模仿奴隶,这会让你容易受到攻击(但就我而言,在私人工作网络上 - 这不是问题.)

这篇关于在 Jenkins 上通过 Java Web Start 启动从代理的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆