feat(nix/buildkite): support meta.timeout

This uses the nixpkgs convention of meta.timeout, and adds a
timeout_in_minutes field to the pipeline step in case its set.

Fixes https://b.tvl.fyi/issues/285.

Change-Id: Ia72e3832f14bf9172319bce070c5b0944f1c96fe
Reviewed-on: https://cl.tvl.fyi/c/depot/+/8970
Autosubmit: flokli <flokli@flokli.de>
Reviewed-by: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
This commit is contained in:
Florian Klink 2023-07-14 19:16:02 +03:00 committed by clbot
parent 6c630aadc8
commit 728de762fd

View file

@ -84,6 +84,8 @@ rec {
# always runs. This allows build steps uploaded in batches to # always runs. This allows build steps uploaded in batches to
# start running before all batches have been uploaded. # start running before all batches have been uploaded.
depends_on = ":init:"; depends_on = ":init:";
} // lib.optionalAttrs (target ? meta.timeout) {
timeout_in_minutes = target.meta.timeout / 60;
}; };
# Helper function to inelegantly divide a list into chunks of at # Helper function to inelegantly divide a list into chunks of at