Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Merge pull request #2545 from Vlatombe/JENKINS-38187
[FIX JENKINS-38187] Fix setting JNLP port through system property (cherry picked from commit 3f5fe7f)
- Loading branch information
Showing
with
130 additions
and 6 deletions.
- +12 −0 core/src/main/java/hudson/security/GlobalSecurityConfiguration.java
- +4 −3 core/src/main/java/jenkins/install/SetupWizard.java
- +61 −1 core/src/main/java/jenkins/model/Jenkins.java
- +12 −2 core/src/main/resources/hudson/security/GlobalSecurityConfiguration/index.groovy
- +3 −0 core/src/main/resources/hudson/security/GlobalSecurityConfiguration/index.properties
- +34 −0 ...src/main/resources/jenkins/model/Jenkins/EnforceSlaveAgentPortAdministrativeMonitor/message.jelly
- +2 −0 ...ain/resources/jenkins/model/Jenkins/EnforceSlaveAgentPortAdministrativeMonitor/message.properties
- +2 −0 core/src/main/resources/jenkins/model/Messages.properties
@@ -0,0 +1,3 @@ | ||
slaveAgentPortEnforced=enforced to {0,number,#} on startup through system property. | ||
slaveAgentPortEnforcedRandom=enforced to random port on startup through system property. | ||
slaveAgentPortEnforcedDisabled=disabled on startup through system property. |
@@ -0,0 +1,34 @@ | ||
<!-- | ||
The MIT License | ||
Copyright (c) 2016, CloudBees, Inc. | ||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
The above copyright notice and this permission notice shall be included in | ||
all copies or substantial portions of the Software. | ||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. | ||
--> | ||
<?jelly escape-by-default='true'?> | ||
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form" xmlns:i="jelly:fmt"> | ||
<div class="warning"> | ||
${%description(it.systemPropertyName, it.expectedPort)} | ||
<form method="post" action="${rootURL}/${it.url}/act" name="${it.id}"> | ||
<div style="float:right"> | ||
<f:submit name="reset" value="${%reset(it.expectedPort)}"/> | ||
</div> | ||
</form> | ||
</div> | ||
</j:jelly> |
@@ -0,0 +1,2 @@ | ||
description=JNLP Agent Port has been changed but was specified through system property {0} on startup. Its value will be reset to {1,number,#} on restart. | ||
reset=Reset to {0,number,#} |