buildbot_travis icon indicating copy to clipboard operation
buildbot_travis copied to clipboard

Choosing the correct worker for a project

Open bendikro opened this issue 8 years ago • 7 comments

I can't find a way to map a project to specific worker or worker types. Is this on the TODO list? I see that travisyml.py has an image attribute, but it's currently not used as far as I can see? Is this meant to handle this in the future?

bendikro avatar Dec 13 '16 15:12 bendikro

It is something that indeed is on the TODO list, and shall go via this image attribute. Actually this is not very complicated to do as the image for docker latent worker is already renderable.

tardyp avatar Dec 16 '16 12:12 tardyp

Yeah, I noticed that was supported for the DockerLatentWorker. Any idea about how this will be handled regarding the lang and image attributes? Say we implement support for LibVirtWorker, we'd need a way to specify which type of worker to use in the .travis.yml?

bendikro avatar Dec 16 '16 14:12 bendikro

I'd say the best is for LibVirtWorker to have some of its parameter rendereable so that they can be chosen according to the properties. Or improve the bbtravis.yml so that it is easier to describe what to do. I fully open to suggestion here

tardyp avatar Dec 16 '16 14:12 tardyp

I would also expect some support for Windows workers. So far, I only see Linux based ones. How hard would it be to implement an 'os' attribute (or a set of worker properties) in the bbtravis.yml ? Like this is currently supported in travis, although only for linux and macos.

pardoc avatar Aug 21 '17 14:08 pardoc

I plan to make a fork of buildbot_travis adding a "labels" attribute to Workers, in order to have a node selection mechanism "à la" Jenkins. But this requires to also change the Worker class in buildbot, and add it a "labels" attribute as well. Is there a way I can avoid this ?

pardoc avatar Sep 04 '17 15:09 pardoc

In buildbot, the way you can do this is to implement and nextWorker callback. You can always add a attribute to your standard buildbot workers, and then look at this attribute in your nextWorker.

tardyp avatar Sep 04 '17 15:09 tardyp

I planned to use canStartBuild, but nextWorker will do as well. The problem is that checkConfig (buildbot.worker.base.AbstractWorker) returns an error on the unexpected "labels" argument I added (in the UI, cfg.yml, and createWorkerConfigWorker). I cannot see how to avoid modifying buildbot itself to make that pass.

pardoc avatar Sep 05 '17 08:09 pardoc