Reputation: 255
I am starting my Pipeline this way:
node('my_Label') { // my code }
I want to know in which Slave my code is running. I tried multiple things but I was not able to find out the correct method to call for that :(
Upvotes: 7
Views: 3560
Reputation: 1101
The environment variable ${NODE_NAME} should have it:
node ('my_Label) {
println "${NODE_NAME}"
}
Upvotes: 10