nixpkgs/pkgs/tools/filesystems/mergerfs/tools.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

37 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub, coreutils, makeWrapper
, rsync, python3 }:
2018-07-14 21:31:01 +00:00
stdenv.mkDerivation rec {
2019-05-16 17:50:51 +00:00
pname = "mergerfs-tools";
version = "20230912";
2018-07-14 21:31:01 +00:00
src = fetchFromGitHub {
owner = "trapexit";
2019-05-16 17:50:51 +00:00
repo = pname;
rev = "80d6c9511da554009415d67e7c0ead1256c1fc41";
hash = "sha256-9sn2ziIjes2squSGbjjXVch2zDFjQruWB4282p4jWcY=";
2018-07-14 21:31:01 +00:00
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ python3 ];
makeFlags = [
"INSTALL=${coreutils}/bin/install"
2019-05-16 17:50:51 +00:00
"PREFIX=${placeholder "out"}"
2018-07-14 21:31:01 +00:00
];
2021-01-15 09:19:50 +00:00
postInstall = with lib; ''
2018-07-14 21:31:01 +00:00
wrapProgram $out/bin/mergerfs.balance --prefix PATH : ${makeBinPath [ rsync ]}
wrapProgram $out/bin/mergerfs.dup --prefix PATH : ${makeBinPath [ rsync ]}
wrapProgram $out/bin/mergerfs.mktrash --prefix PATH : ${makeBinPath [ python3.pkgs.xattr ]}
2018-07-14 21:31:01 +00:00
'';
meta = with lib; {
2018-07-14 21:31:01 +00:00
description = "Optional tools to help manage data in a mergerfs pool";
2019-05-16 17:50:51 +00:00
homepage = "https://github.com/trapexit/mergerfs-tools";
2018-07-14 21:31:01 +00:00
license = licenses.isc;
platforms = platforms.linux;
maintainers = with maintainers; [ makefu ];
2018-07-14 21:31:01 +00:00
};
}