Subject: [bug#45006] cuirass: Add remote build support.

From: Mathieu Othacehe <[email-masked]>
Date: Mon, 21 Dec 2020 14:40:36 +0100

Hello,

There's a new variant of this patch on the wip-offload branch of
Cuirass. Quite a few things have changed since the first version:

* The "remote-server" no longer communicates directly with Cuirass, all
  the exchanges are done through the database.

* The "remote-worker" now honors "timeout" and "max-silent-time" package
  parameters.

* I have added build priorities support. The build priority is computed
  this way:

build_priority = specification_priority * 10 + package_priority

* There's a new "worker" table that stores what workers are currently
  building, and an associated "/workers" page.

* The "remote-worker" can connect to a "remote-server" specified on the
  command line.

* The substitutes are downloaded and stored in the publish cache directory.

I have deployed another Cuirass instance on berlin using this mechanism
and workers on all build machines. It's been building
master/core-updated/staging/modular specifications since a few days for
x86_64-linux and i686-linux architectures.

The results are really better than using the current implementation and
it should be possible to transition to this new architecture soon.

Thanks,

Mathieu