Thanks for the report. I'm able to duplicate the issue with the following steps:
- Define the plugins to be downloaded and installed in a plugins.txt
file
- Create a script to download plugins and start Jenkins like run-jenkins.sh
![](/images/icons/link_attachment_7.gif)
- Run the script bash ./run-jenkins.sh
- Complete the setup wizard using the password shown in the console output, choosing to install no additional plugins
- Open the node management page at /computer/ and click the "New node" button
- Complete the fields of the form and be sure to select "Launch swarm agent" as the "Launch method"
- Save the form and confirm that a stack trace is reported in the console log and an error is displayed on the web page
I believe the root of the bug is that Jenkins is offering you the option to create a swarm agent but that is not how swarm agents are documented to be started. The swarm agent plugin documentation says:
- Install the Swarm plugin from the Update Center.
- Ensure your agent is running version 11 or later of the Java Runtime Environment (JRE). The recommendation is to use the same JRE distribution and version as the controller.
- Download the Swarm client from ${JENKINS_URL}/swarm/swarm-client.jar on your agent.
- Run the Swarm client with java -jar path/to/swarm-client.jar -url ${JENKINS_URL} -username ${USERNAME} and one of the authentication options as described in the Global Security Configuration documentation. There are no other required command-line options; run with the -help option to see the available options.
It is not intended that the administrator will use the "New node" page to define a swarm agent. Swarm agents are created and destroyed inside Jenkins automatically as the swarm agent processes connect to Jenkins and disconnect from Jenkins. The "Launch swarm agent" selection from the menu on the "New node" page is providing an incorrect hint that it is supported to define Jenkins swarm agents from the controller.
If you'd like to use swarm agents, you need to follow the "Getting started" instructions from the swarm agent plugin documentation.
If you'd like more information on managing Jenkins agents, refer to https://www.jenkins.io/doc/book/managing/nodes/ for descriptions and videos.
Thanks for the report. I'm able to duplicate the issue with the following steps:
I believe the root of the bug is that Jenkins is offering you the option to create a swarm agent but that is not how swarm agents are documented to be started. The swarm agent plugin documentation says:
It is not intended that the administrator will use the "New node" page to define a swarm agent. Swarm agents are created and destroyed inside Jenkins automatically as the swarm agent processes connect to Jenkins and disconnect from Jenkins. The "Launch swarm agent" selection from the menu on the "New node" page is providing an incorrect hint that it is supported to define Jenkins swarm agents from the controller.
If you'd like to use swarm agents, you need to follow the "Getting started" instructions from the swarm agent plugin documentation.
If you'd like more information on managing Jenkins agents, refer to https://www.jenkins.io/doc/book/managing/nodes/ for descriptions and videos.