about summary refs log tree commit diff
path: root/pkgs/applications/networking/cluster/kfilt/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/applications/networking/cluster/kfilt/default.nix')
-rw-r--r--pkgs/applications/networking/cluster/kfilt/default.nix31
1 files changed, 31 insertions, 0 deletions
diff --git a/pkgs/applications/networking/cluster/kfilt/default.nix b/pkgs/applications/networking/cluster/kfilt/default.nix
new file mode 100644
index 000000000000..dd85bd8bbddc
--- /dev/null
+++ b/pkgs/applications/networking/cluster/kfilt/default.nix
@@ -0,0 +1,31 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "kfilt";
+  version = "0.0.8";
+
+  src = fetchFromGitHub {
+    owner = "ryane";
+    repo = "kfilt";
+    rev = "v${version}";
+    hash = "sha256-TUhZKf4fJyJF/qDmvs4jqAMVTXN4MXE+YLc4FcOVlwo=";
+  };
+
+  vendorHash = "sha256-c77CzpE9cPyobt87uO0QlkKD+xC/tM7wOy4orM62tnI=";
+
+  subPackages = [ "." ];
+
+  ldflags = [
+    "-s"
+    "-w"
+    "-X github.com/ryane/kfilt/cmd.Version=${version}"
+    "-X github.com/ryane/kfilt/cmd.GitCommit=${src.rev}"
+  ];
+
+  meta = {
+    description = "Command-line tool that filters Kubernetes resources";
+    homepage = "https://github.com/ryane/kfilt";
+    license = lib.licenses.asl20;
+    maintainers = [ lib.maintainers.ryane ];
+  };
+}