Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I can't find "Restrict where this project can be run" in the configure page

Tags:

I use Jenkins,I can't find "Restrict where this project can be run" in the configure page,should I add some plugins? which one?

like image 484
Tracy Theron Avatar asked Feb 20 '13 08:02

Tracy Theron


People also ask

What is restrict where this project can be run in Jenkins?

Set the "Restrict where this job can be run" check box in your job configuration and specify the name of your slave. If you add more slaves later, you can set labels for each slave and specify those in your job configs. See this reference documentation: https://wiki.jenkins-ci.org/display/JENKINS/Distributed+builds.

How do I run a Jenkins job on a specific node?

In test_job's configuration, select 'This build is parameterized' and add a Node parameter and set the parameter name to node_name. In pipeline add Choice parameter, name it node , put there possible choices, so running pipeline you can choose on which node it should be run.

Can a single Jenkins job run on multiple nodes?

Save the Job Configuration and Build the Job according to your requirement. Step 1− If multi node selection was enabled, you get the chance to select multiple nodes to run the job on. The job will then be executed on each of the nodes, one after the other or concurrent - depending on the configuration.

Which plugin can be used to assign the cleanup jobs to the specific nodes?

Freestyle jobs The plugin provides a build wrapper (Delete workspace before build starts) and a post build step (Delete workspace when build is done). These steps allow you to configure which files will be deleted and in what circumstances. The post build step can also take the build status into account.


2 Answers

This is because you have not yet added any new nodes to your Jenkins set up. Till then the master(where you have installed Jenkins) is the only available machine where jobs can be run. So there is no need to ask where the job needs to be restricted to be run.

Check this link to see how to add a new node to your jenkins setup. Once you add a new node, you will see the option of "Restrict where this project can be run".

like image 137
Shiva Kumar Avatar answered Sep 20 '22 18:09

Shiva Kumar


This is because you have not added any label to your master node (if you don't have slaves).

This is a bit weird because you could also use the node name (i.e. 'master') to restrict the executor node, not only the label, and you may want to do this before you add further slaves.

like image 22
maxrossello Avatar answered Sep 20 '22 18:09

maxrossello