Skip to content

Commit

Permalink
Changing formatting of status page when disconnected to reflect fewer…
Browse files Browse the repository at this point in the history
… options
  • Loading branch information
jglick committed May 6, 2022
1 parent dccc475 commit 13b934c
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions core/src/main/resources/hudson/slaves/JNLPLauncher/main.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -33,35 +33,26 @@ THE SOFTWARE.
</j:when>
<j:when test="${it.offline and !it.temporarilyOffline}">
<j:if test="${h.hasPermission(it, it.CONNECT)}">
<p>
${%Connect agent to Jenkins one of these ways:}
</p>
<ul>
<j:choose>
<j:when test="${it.ACL.hasPermission(app.ANONYMOUS, it.CONNECT)}">
<li>
<p>
${%Run from agent command line:}
</p>
<pre>java${it.launcher.vmargs == null ? '' : ' ' + it.launcher.vmargs} -jar <a href="${rootURL}/jnlpJars/agent.jar">agent.jar</a> -jnlpUrl ${h.inferHudsonURL(request)}${it.url}jenkins-agent.jnlp ${it.launcher.getWorkDirOptions(it)}</pre>
</li>
</j:when>
<j:otherwise>
<li>
<p>
${%Run from agent command line:}
</p>
<!-- TODO conceal secret w/ JS if possible -->
<pre>java${it.launcher.vmargs == null ? '' : ' ' + it.launcher.vmargs} -jar <a href="${rootURL}/jnlpJars/agent.jar">agent.jar</a> -jnlpUrl ${h.inferHudsonURL(request)}${it.url}jenkins-agent.jnlp -secret ${it.jnlpMac} ${it.launcher.getWorkDirOptions(it)}</pre>
<p>
${%Run from agent command line, with the secret stored in a file:}
${%Or run from agent command line, with the secret stored in a file:}
</p>
<pre>echo ${it.jnlpMac} > secret-file
java${it.launcher.vmargs == null ? '' : ' ' + it.launcher.vmargs} -jar <a href="${rootURL}/jnlpJars/agent.jar">agent.jar</a> -jnlpUrl ${h.inferHudsonURL(request)}${it.url}jenkins-agent.jnlp -secret @secret-file ${it.launcher.getWorkDirOptions(it)}</pre>
</li>
</j:otherwise>
</j:choose>
</ul>
<!--
<p>
<a href="custom-jnlp" style="margin-left:3em">
Expand Down

0 comments on commit 13b934c

Please sign in to comment.