depot/third_party/nixpkgs/pkgs/servers/search/meilisearch/default.nix
Default email 13da32182d Project import generated by Copybara.
GitOrigin-RevId: a7855f2235a1876f97473a76151fec2afa02b287
2022-08-21 15:32:41 +02:00

40 lines
1.1 KiB
Nix

{ stdenv
, lib
, rustPlatform
, fetchFromGitHub
, Security
, DiskArbitration
, Foundation
, nixosTests
}:
let version = "0.23.1";
in
rustPlatform.buildRustPackage {
pname = "meilisearch";
inherit version;
src = fetchFromGitHub {
owner = "meilisearch";
repo = "MeiliSearch";
rev = "v${version}";
sha256 = "sha256-4F7noByC9ZgqYwPfkm8VE15QU2jbBvUAH4Idxa+J+Aw=";
};
cargoPatches = [
# feature mini-dashboard tries to download a file from the internet
# feature analitycs should be opt-in
./remove-default-feature.patch
];
cargoSha256 = "sha256-dz+1IQZRSeMEagI2dnOtR3A8prg4UZ2Om0pd1BUhuhE=";
buildInputs = lib.optionals stdenv.isDarwin [ Security DiskArbitration Foundation ];
passthru.tests = {
meilisearch = nixosTests.meilisearch;
};
meta = with lib; {
broken = (stdenv.isDarwin && stdenv.isx86_64);
description = "Powerful, fast, and an easy to use search engine ";
homepage = "https://docs.meilisearch.com/";
license = licenses.mit;
maintainers = with maintainers; [ happysalada ];
platforms = [ "aarch64-darwin" "x86_64-linux" "x86_64-darwin" ];
};
}