Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
78 lines
1.7 KiB
Nix
78 lines
1.7 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
buildGoModule,
|
|
fetchFromGitHub,
|
|
libredirect,
|
|
iana-etc,
|
|
testers,
|
|
seaweedfs,
|
|
}:
|
|
|
|
buildGoModule (finalAttrs: {
|
|
pname = "seaweedfs";
|
|
version = "3.97";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "seaweedfs";
|
|
repo = "seaweedfs";
|
|
tag = finalAttrs.version;
|
|
hash = "sha256-h8pyjC/hbKfvt4hEKuq0v5osLMWNU+6mYqFGqsZFqXs=";
|
|
};
|
|
|
|
vendorHash = "sha256-KRO0aDGOVx1neXcGsYYqcpD0tAqtR3GSBDhFz5TbQBs=";
|
|
|
|
nativeBuildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ libredirect.hook ];
|
|
|
|
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 and those that require additional services.
|
|
rm -rf unmaintained test/s3 test/fuse_integration
|
|
# TestECEncodingVolumeLocationTimingBug, TestECEncodingMasterTimingRaceCondition: weed binary not found
|
|
export PATH=$PATH:$NIX_BUILD_TOP/go/bin
|
|
''
|
|
+ lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
export NIX_REDIRECTS=/etc/protocols=${iana-etc}/etc/protocols:/etc/services=${iana-etc}/etc/services
|
|
'';
|
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
passthru.tests.version = testers.testVersion {
|
|
package = seaweedfs;
|
|
command = "weed version";
|
|
};
|
|
|
|
meta = {
|
|
description = "Simple and highly scalable distributed file system";
|
|
homepage = "https://github.com/chrislusf/seaweedfs";
|
|
maintainers = with lib.maintainers; [
|
|
azahi
|
|
cmacrae
|
|
wozeparrot
|
|
];
|
|
mainProgram = "weed";
|
|
license = lib.licenses.asl20;
|
|
};
|
|
})
|