I set up a Jenkins Server with the swarm plugin and write a batch to autostart slaves. My Batch file looks like:
java -jar swarm-client-2.2-jar-with-dependencies.jar -mode exclusive
-master http://localhost:8080 -disableClientsUniqueId -username
MyUser -password ***** -executors 1 -labels MySlave
My Problem is, the slave is always adding the Label swarm.
My Question is:
How can I prevent the plugin from setting up swarm as a Label ?
I sympathize with the desire to perfectly control the labels attached to a slave, whether it's connected through the Swarm Plugin or not. But the source code makes it look like that "swarm" label is a mandatory prefix to the list of labels: https://github.com/jenkinsci/swarm-plugin/blob/ef02020595d0546b527b84a2e47bc75cde1e6e1a/plugin/src/main/java/hudson/plugins/swarm/PluginImpl.java#L199
The answer may be that you cannot avoid that label without forking the Swarm Plugin and updating that line.