set correct slave port from env
>groovy.lang.MissingPropertyException: No such property: env for class: tcp-slave-agent-port
This commit is contained in:
parent
01b970ddf2
commit
1a6501604a
|
@ -5,6 +5,8 @@ import jenkins.model.*;
|
|||
Thread.start {
|
||||
sleep 10000
|
||||
println "--> setting agent port for jnlp"
|
||||
Jenkins.instance.setSlaveAgentPort(env['JENKINS_SLAVE_AGENT_PORT'])
|
||||
def env = System.getenv()
|
||||
int port = env['JENKINS_SLAVE_AGENT_PORT'].toInteger()
|
||||
Jenkins.instance.setSlaveAgentPort(port)
|
||||
println "--> setting agent port for jnlp... done"
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue