Commit fd2cba03 authored by MaxHearnden's avatar MaxHearnden
Browse files

nomad: use $NIX_BUILD_TOP for build directory

The preCheck step would add /build/go/bin to PATH which is incorrect
when the build directory is somewhere else (e.g. on most mac systems)

fixes https://github.com/NixOS/nixpkgs/issues/251885
parent efed6046
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -82,7 +82,7 @@ rec {
    vendorSha256 = "sha256-y3WiQuoQn6SdwTgtPWuB6EBtsJC+YleQPzownZQNkno=";
    passthru.tests.nomad = nixosTests.nomad;
    preCheck = ''
      export PATH="$PATH:/build/go/bin"
      export PATH="$PATH:$NIX_BUILD_TOP/go/bin"
    '';
  };

@@ -93,7 +93,7 @@ rec {
    vendorSha256 = "sha256-Y3O7ADzZPlLWFbXSYBcI6b5MAhMD0UnkhQxO9VJMpOY=";
    passthru.tests.nomad = nixosTests.nomad;
    preCheck = ''
      export PATH="$PATH:/build/go/bin"
      export PATH="$PATH:$NIX_BUILD_TOP/go/bin"
    '';
  };
}