about summary refs log tree commit diff
path: root/pkgs/servers/redpanda
diff options
context:
space:
mode:
authorhappysalada <raphael@megzari.com>2022-05-02 19:49:02 -0400
committerYt <raphael@megzari.com>2022-05-02 20:32:21 -0400
commitd60e768cb1560188df672c5d08ef962ba81d96be (patch)
treea292738413f77dd3f2aab41bf31ccd273eef42cf /pkgs/servers/redpanda
parentd770c33587d1ad73b0959c88479439c4aaa1dd90 (diff)
redpanda: init at 21.11.15
Diffstat (limited to 'pkgs/servers/redpanda')
-rw-r--r--pkgs/servers/redpanda/default.nix35
1 files changed, 35 insertions, 0 deletions
diff --git a/pkgs/servers/redpanda/default.nix b/pkgs/servers/redpanda/default.nix
new file mode 100644
index 0000000000000..6b0704b04a598
--- /dev/null
+++ b/pkgs/servers/redpanda/default.nix
@@ -0,0 +1,35 @@
+{ lib, stdenv, fetchzip }:
+
+let
+  version = "21.11.15";
+  platform = if stdenv.isLinux then "linux" else "darwin";
+  arch = if stdenv.isAarch64 then "arm" else "amd";
+in stdenv.mkDerivation rec {
+  pname = "redpanda";
+  inherit version;
+
+  src = fetchzip {
+    url = "https://github.com/redpanda-data/redpanda/releases/download/v${version}/rpk-${platform}-${arch}64.zip";
+    sha256 = "sha256-Yf4O7lVcf+nmb0wFTx7jLjUSmdAItoUfPlkhHveI9UY=";
+  };
+
+  installPhase = ''
+    runHook preInstall
+
+    mkdir -p $out/bin
+    cp rpk $out/bin
+
+    runHook postInstall
+  '';
+
+  # stripping somehow completely breaks it
+  dontStrip = true;
+
+  meta = with lib; {
+    description = "Redpanda is a streaming data platform for developers. Kafka API compatible. 10x faster. No ZooKeeper. No JVM! ";
+    license = licenses.bsl11;
+    homepage = "https://redpanda.com/";
+    maintainers = with maintainers; [ happysalada ];
+    platforms = platforms.all;
+  };
+}