Reputation: 2784
If I have job that invokes series of jobs in jenkins can I give them all parameter to tie them up to a specific server?
I talk about the "Restrict where this project can be run" that currently I need to specifiy in the project level (can I give it as input parameter?)
Upvotes: 4
Views: 12581
Reputation: 177
Use this plugin: https://wiki.jenkins-ci.org/display/JENKINS/NodeLabel+Parameter+Plugin
You can provide a parameter to the job via either the ParameterizedTrigger or using the API and providing the node name (or label).
Upvotes: 8
Reputation: 5114
You should be a able to create a string input parameter and then use that in the "Restrict where this project can be run" box. So if your string parameter was called TAG you would put ${TAG}
in the box.
You could then use the Parameterized Trigger Plugin to pass this to downstream jobs, essentially tying all of them to the same node.
Upvotes: 4