depot/third_party/nixpkgs/pkgs/servers/nosql/questdb/default.nix
Default email 5e9e1146e1 Project import generated by Copybara.
GitOrigin-RevId: 18036c0be90f4e308ae3ebcab0e14aae0336fe42
2023-08-05 00:07:22 +02:00

37 lines
1,012 B
Nix

{ fetchurl, jdk17_headless, lib, makeWrapper, stdenv }:
let
jre = jdk17_headless;
in
stdenv.mkDerivation rec {
pname = "questdb";
version = "7.2.1";
src = fetchurl {
url = "https://github.com/questdb/questdb/releases/download/${version}/questdb-${version}-no-jre-bin.tar.gz";
sha256 = "sha256-PtVY1cZl/2RQ3YaEBVXpAoZrMRQbv7d1BDFdTwXI+Uk=";
};
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
runHook preInstall
mkdir -p $out/bin $out/share/java
cp questdb.sh $out/bin
cp questdb.jar $out/share/java
ln -s $out/share/java/questdb.jar $out/bin
wrapProgram $out/bin/questdb.sh --set JAVA_HOME "${jre}"
runHook postInstall
'';
meta = with lib; {
description = "high-performance, open-source SQL database for applications in financial services, IoT, machine learning, DevOps and observability";
homepage = "https://questdb.io/";
license = licenses.asl20;
maintainers = [ maintainers.jacfal ];
platforms = platforms.linux;
};
}