Support testing build determinism

Builds can now specify the attribute "isDeterministic = true" to tell
Hydra to build with build-repeat > 0. If there is a mismatch between
rounds, the step / build fails with a suitable status.

Maybe this should be a meta attribute, but that makes it invisible to
hydra-queue-runner, and it seems reasonable to make a claim of
mandatory determinism part of the derivation (since e.g. enabling this
flag should trigger a rebuild).
This commit is contained in:
Eelco Dolstra
2016-12-06 17:46:06 +01:00
parent d0ad3fd806
commit 8bb36e79bd
6 changed files with 21 additions and 1 deletions

View File

@ -418,6 +418,7 @@ Step::ptr State::createStep(ref<Store> destStore,
step->drv = readDerivation(drvPath);
step->preferLocalBuild = step->drv.willBuildLocally();
step->isDeterministic = get(step->drv.env, "isDetermistic", "0") == "1";
step->systemType = step->drv.platform;
{