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

Add a new template to SOME docker clouds

    Details

    • Similar Issues:

      Description

      Summary

      We utilize the docker plugin to automatically create docker images from Dockerfiles in the source code to provide build nodes that fit the requirements of the code base.

      For this reason we use the "add a new template to all docker clouds" build step to automatically provide the docker container configuration in all servers inside the cloud.

      Recently we notices that this causes a problem if the servers in the cloud are not identical in their hardware setup. For example a build might fail randomly if it's build container is launched on a host with less RAM than the others.

      The obvious solution of cause is to remove the "offending" host, but as 90% of our jobs can run fine on it we want to keep it.

      We also see scenarios coming up in which the cloud will contain specialized servers meant for only one kind of task where we do not want all jobs and their containers to spread to or scenarios in which users should be able to spread their config via the job configuration to part of the clouds while the rest would be privileged to only host containers configured in the main configuration.

      Request

      We would like to have the option to exclude some server(s) from the "add a new template to all docker clouds" build step, so we could still utilize it to spread the configuration to most of the servers, but exclude the one(s) with less RAM, CPU or whatever else might make them special / unsubtle for the containers.

      I imagine this could either be done by adding an exclude list to the build step configuration or by adding the option to "do not use this cloud for automatic template publishing" in the main cloud config. The latter would also satisfy the concept of privileged usage of these servers so users would not be able to add their containers to these clouds without administrative access. 

        Attachments

          Activity

          Hide
          pjdarton pjdarton added a comment -

          The old "add a new template to all docker clouds" is crude and does not allow for much functionality as-is.
          Personally, I'd recommend that you use some custom pipeline code to sift through the clouds that are configured, locate any existing template(s) within those clouds that you want replaced, and then replace them.
          As pipeline code is "just groovy" you should be able to do all of that and, as you've got groovy's capabilities, you'll be able to implement the functionality you required.

          Show
          pjdarton pjdarton added a comment - The old "add a new template to all docker clouds" is crude and does not allow for much functionality as-is. Personally, I'd recommend that you use some custom pipeline code to sift through the clouds that are configured, locate any existing template(s) within those clouds that you want replaced, and then replace them. As pipeline code is "just groovy" you should be able to do all of that and, as you've got groovy's capabilities, you'll be able to implement the functionality you required.

            People

            • Assignee:
              Unassigned
              Reporter:
              paul_muller Paul Muller
            • Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated: