forgejo-lts: 7.0.10 -> 7.0.11
[NixPkgs.git] / pkgs / servers / metabase / default.nix
blobf7da4dc0eafc3523262518a5c98f40645d1467a1
1 { lib, stdenv, fetchurl, makeWrapper, jdk11, nixosTests }:
3 stdenv.mkDerivation rec {
4   pname = "metabase";
5   version = "0.50.30";
7   src = fetchurl {
8     url = "https://downloads.metabase.com/v${version}/metabase.jar";
9     hash = "sha256-55B80V6xcWVM/gSGrQ3bh97AFigwOuMQ/0zHcyDBcfE=";
10   };
12   nativeBuildInputs = [ makeWrapper ];
14   dontUnpack = true;
16   installPhase = ''
17     runHook preInstall
18     makeWrapper ${jdk11}/bin/java $out/bin/metabase --add-flags "-jar $src"
19     runHook postInstall
20   '';
22   meta = with lib; {
23     description = "Easy, open source way for everyone in your company to ask questions and learn from data";
24     homepage    = "https://metabase.com";
25     sourceProvenance = with sourceTypes; [ binaryBytecode ];
26     license     = licenses.agpl3Only;
27     platforms   = platforms.all;
28     maintainers = with maintainers; [ schneefux thoughtpolice mmahut ];
29     mainProgram = "metabase";
30   };
31   passthru.tests = {
32     inherit (nixosTests) metabase;
33   };