The Startup Trigger plugin allows you to trigger a build when Jenkins nodes (controller/agent) start.
Hey dude! Help me out for a couple of 🍻 or a ☕!
This plugin requires a jenkins restart (it will not work using install without restart). After installation you will find a new Build Trigger "Build when job nodes start" tickbox is available in the job configuration of each job.
By default this value is blank and the job will start (once) whenever the Jenkins controller starts. Alternatively, you can specify a node label or a space separated list of nodes labels like:
Or a label expression:
LABEL_A && LABEL_B
This plugin will trigger builds when any node matching this/these labels is started. This includes when the controller is restarted, as each matching node reconnects the job will be re-executed.
Defaults to zero, allows you to specify the Quiet Period before scheduling the job.
The parameter name for Startup Trigger to use when specifying which node triggered the job. Useful if the default NodeLabelParameter value is a label and you want to run the job on the node that triggered the job's execution.
This can also reference a StringParameter, if instead you want the name of the started node to be handed to a job as an argument.
This pulldown provides a few options for what types of startup events should trigger builds:
- Run on initial connection (Default)
- This will trigger when a node first connects to Jenkins (JNLP, SSH, DCOM, etc..)
- Run when node brought online
- This will trigger when a node is "Temporarily Reconnected". For example: Node was previously "Marked as offline" and has now been brought online.
- Use this value to specify that both events should trigger build execution
This plugin seems to build successfully in all versions of Maven. The current release (2.9.4) builds with
3.9.4. Startup-Trigger builds with Temurin's JDK 11 and 17.