Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rest API for disconnect/reconnect slave from Jenkins

Tags:

jenkins

I know we can post the following to offline a slave on Jenkins

http://[jenkins_url]:8080/computer/[slave_name]/toggleOffline?offlineMessage=bye

but is there one for disconnecting and connecting slave?

like image 859
TheTeaRex Avatar asked Mar 09 '17 23:03

TheTeaRex


Video Answer


1 Answers

I ended up had to guess the api, but at least I found it. For those who are interested, there are the api link to disconnect and reconnect a slave agent to Jenkins.

Disconnect: http://[jenkins_url]:8080/computer/[slave_name]/doDisconnect?offlineMessage=bye

Reconnect: http://[jenkins_url]:8080/computer/[slave_name]/launchSlaveAgent

like image 99
TheTeaRex Avatar answered Oct 13 '22 04:10

TheTeaRex