depot/third_party/nixpkgs/pkgs/applications/networking/seaweedfs/default.nix
Default email 472aeafc57 Project import generated by Copybara.
GitOrigin-RevId: c31898adf5a8ed202ce5bea9f347b1c6871f32d1
2024-10-04 18:56:33 +02:00

61 lines
1.2 KiB
Nix

{ lib
, fetchFromGitHub
, buildGoModule
, testers
, seaweedfs
}:
buildGoModule rec {
pname = "seaweedfs";
version = "3.75";
src = fetchFromGitHub {
owner = "seaweedfs";
repo = "seaweedfs";
rev = version;
hash = "sha256-f4ddm9+A3Km0aKlKFeoFMKxm94u0pbNvHaozesmQCH4=";
};
vendorHash = "sha256-hdvlz3KbB6wPva3o5suEApgZ6w98R8TPYrPlmqYJbvo=";
subPackages = [ "weed" ];
ldflags = [
"-w"
"-s"
"-X github.com/seaweedfs/seaweedfs/weed/util.COMMIT=N/A"
];
tags = [
"elastic"
"gocdk"
"sqlite"
"ydb"
"tikv"
];
preBuild = ''
export GODEBUG=http2client=0
'';
preCheck = ''
# Test all targets.
unset subPackages
# Remove unmaintained tests ahd those that require additional services.
rm -rf unmaintained test/s3
'';
passthru.tests.version = testers.testVersion {
package = seaweedfs;
command = "weed version";
};
meta = with lib; {
description = "Simple and highly scalable distributed file system";
homepage = "https://github.com/chrislusf/seaweedfs";
maintainers = with maintainers; [ azahi cmacrae wozeparrot ];
mainProgram = "weed";
license = licenses.asl20;
};
}