Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-12998

Allows variable subistution for Job 'Restrict where this project can be run' label expression

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Won't Fix
    • Icon: Major Major
    • core
    • Windows Server 2008 SP2

      Allow variable substitution for the 'Restrict where this project can be run' label expression field of the job configuration.

      Substitution of the form ${BRANCH} where BRANCH is a parameter to the job, will allow the job to run on any node with a label which matches BRANCH.

      Motivation.
      We have large branches which can take several hours to checkout from fresh. We therefore need to ensure that jobs are run on slaves which already have the branch checkedout in order to keep build times at acceptiable levels. Atm we have some Jobs which we need to be able to run on any branch, these jobs have a parameter BRANCH which is currently used to by the perforce plugin to set the correct depot path. Depending on the number of files which needs to be synced this can cause a significant delay in build times.
      The alternative is to duplicate the job and hardcode the node label for each branch, this solves the re-sync issue but causes duplicated jobs and a maintiance headache. Not to mention it clutters the interface and confuses the users.

      Having parameter subistution on the node label field would allow us to specify which slave group to use for which branches and then have Jenkins take care of all of the management.

      Hopefully this is a quick and easy feature to add.

      Many thanks

            Unassigned Unassigned
            richardtaylor Richard Taylor
            Votes:
            7 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: