From f7f3ec9a37d8bc1cb3f612f8eab8cfbbb1740708 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Mon, 20 Apr 2020 15:37:46 +0800 Subject: [PATCH] nixbld: update hydra --- nixbld-etc-nixos/configuration.nix | 3 ++- nixbld-etc-nixos/hydra-retry.patch | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/nixbld-etc-nixos/configuration.nix b/nixbld-etc-nixos/configuration.nix index 4668c3a..48c8976 100644 --- a/nixbld-etc-nixos/configuration.nix +++ b/nixbld-etc-nixos/configuration.nix @@ -243,6 +243,7 @@ in ]; services.hydra = { enable = true; + package = pkgs.hydra-unstable; useSubstitutes = true; hydraURL = "https://nixbld.m-labs.hk"; notificationSender = "hydra@m-labs.hk"; @@ -358,7 +359,7 @@ in nixpkgs.config.packageOverrides = super: let self = super.pkgs; in { firmwareLinuxNonfree = super.callPackage ./firmware-linux-nonfree.nix {}; - hydra-migration = super.hydra-migration.overrideAttrs(oa: { + hydra-unstable = super.hydra-unstable.overrideAttrs(oa: { patches = oa.patches or [] ++ [ ./hydra-conda.patch ./hydra-retry.patch ]; hydraPath = oa.hydraPath + ":" + super.lib.makeBinPath [ super.jq ]; }); diff --git a/nixbld-etc-nixos/hydra-retry.patch b/nixbld-etc-nixos/hydra-retry.patch index 36f22c3..4221ced 100644 --- a/nixbld-etc-nixos/hydra-retry.patch +++ b/nixbld-etc-nixos/hydra-retry.patch @@ -13,7 +13,7 @@ index 69c430eb..bdbc808d 100644 case BuildResult::TransientFailure: result.stepStatus = bsFailed; - result.canRetry = true; -+ result.canRetry = get(step->drv.env, "__hydraRetry", "1") == "1"; ++ result.canRetry = get(step->drv->env, "__hydraRetry").value_or("1") == "1"; result.errorMsg = ""; break; case BuildResult::TimedOut: