nixpkgs/pkgs/tools/networking/ghz/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

40 lines
818 B
Nix
Raw Normal View History

2023-07-01 22:49:50 +00:00
{ lib, buildGoModule, fetchFromGitHub, testers, ghz }:
buildGoModule rec {
pname = "ghz";
2024-05-30 01:45:25 +00:00
version = "0.120.0";
src = fetchFromGitHub {
owner = "bojand";
repo = "ghz";
rev = "v${version}";
2024-05-30 01:45:25 +00:00
sha256 = "sha256-EzyQbMoR4veHbc9VaNfiXMi18wXbTbDPfDxo5NCk7CE=";
};
2024-05-30 01:45:25 +00:00
vendorHash = "sha256-7TrYWmVKxHKVTyiIak7tRYKE4hgG/4zfsM76bJRxnAk=";
subPackages = [ "cmd/ghz" "cmd/ghz-web" ];
2023-07-01 22:45:34 +00:00
ldflags = [
"-s"
"-w"
"-X=main.version=${version}"
];
2023-07-01 22:49:50 +00:00
passthru.tests = {
version = testers.testVersion {
package = ghz;
};
web-version = testers.testVersion {
package = ghz;
command = "ghz-web -v";
};
};
meta = with lib; {
description = "Simple gRPC benchmarking and load testing tool";
homepage = "https://ghz.sh";
license = licenses.asl20;
};
}