about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMario Rodas <marsam@users.noreply.github.com>2022-05-20 04:03:47 -0500
committerGitHub <noreply@github.com>2022-05-20 04:03:47 -0500
commit4081a307af2c4e00e492f4dfdb60f2629afe6359 (patch)
tree1e1f13d6dd503f5e15c9471e318fcedf7f1ecbf8
parent682a196eee7fb5476a229b60795e1bdbd885186b (diff)
parenta2be0bf196bca07e965ea3d6df2cb96d383e2ea7 (diff)
Merge pull request #169876 from aaronjheng/toxiproxy
toxiproxy: 2.1.4 -> 2.4.0
-rw-r--r--pkgs/development/tools/toxiproxy/default.nix22
1 files changed, 14 insertions, 8 deletions
diff --git a/pkgs/development/tools/toxiproxy/default.nix b/pkgs/development/tools/toxiproxy/default.nix
index 5ecd6ad2eb6f1..c3b77e4b3e27d 100644
--- a/pkgs/development/tools/toxiproxy/default.nix
+++ b/pkgs/development/tools/toxiproxy/default.nix
@@ -1,26 +1,32 @@
-{ lib, buildGoPackage, fetchFromGitHub }:
+{ lib, buildGoModule, fetchFromGitHub }:
 
-buildGoPackage rec {
+buildGoModule rec {
   pname = "toxiproxy";
-  version = "2.1.4";
+  version = "2.4.0";
+
   src = fetchFromGitHub {
     owner = "Shopify";
     repo = "toxiproxy";
     rev = "v${version}";
-    sha256 = "07yhsvscdv1qjfc2fyyh9qsrrdwrrw04wadk5gaq4qddcway7vig";
+    sha256 = "sha256-vFf1yLpAa+yO1PCE+pLTnvvtROtpVxlEgACDNNUWBEM=";
   };
 
-  goPackagePath = "github.com/Shopify/toxiproxy";
-  subPackages = ["cmd" "cli"];
-  ldflags = [ "-X github.com/Shopify/toxiproxy.Version=v${version}" ];
+  vendorSha256 = "sha256-mrRMyIU6zeyAT/fXbBmtMlZzpyeB45FQmYJ4FDwTRTo=";
+
+  excludedPackages = [ "test/e2e" ];
+
+  ldflags = [ "-s" "-w" "-X github.com/Shopify/toxiproxy/v2.Version=${version}" ];
+
+  checkFlags = [ "-short" ];
 
   postInstall = ''
     mv $out/bin/cli $out/bin/toxiproxy-cli
-    mv $out/bin/cmd $out/bin/toxiproxy-cmd
+    mv $out/bin/server $out/bin/toxiproxy-server
   '';
 
   meta = {
     description = "Proxy for for simulating network conditions";
+    homepage = "https://github.com/Shopify/toxiproxy";
     maintainers = with lib.maintainers; [ avnik ];
     license = lib.licenses.mit;
   };