2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript, makeWrapper }:
|
2017-12-31 09:12:41 +00:00
|
|
|
|
2019-11-10 01:13:39 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2017-12-31 09:12:41 +00:00
|
|
|
pname = "lvmsync";
|
2019-08-13 21:52:01 +00:00
|
|
|
version = (import ./gemset.nix).${pname}.version;
|
2017-12-31 09:12:41 +00:00
|
|
|
|
2022-08-15 03:40:21 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2017-12-31 09:12:41 +00:00
|
|
|
|
2021-07-17 20:20:18 +00:00
|
|
|
dontUnpack = true;
|
2017-12-31 09:12:41 +00:00
|
|
|
|
2019-11-10 01:13:39 +00:00
|
|
|
installPhase = let
|
|
|
|
env = bundlerEnv {
|
|
|
|
name = "${pname}-${version}-gems";
|
|
|
|
ruby = ruby;
|
|
|
|
gemfile = ./Gemfile;
|
|
|
|
lockfile = ./Gemfile.lock;
|
|
|
|
gemset = ./gemset.nix;
|
|
|
|
};
|
|
|
|
in ''
|
2017-12-31 09:12:41 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
makeWrapper ${env}/bin/lvmsync $out/bin/lvmsync
|
|
|
|
'';
|
|
|
|
|
2019-07-22 12:02:47 +00:00
|
|
|
passthru.updateScript = bundlerUpdateScript "lvmsync";
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2017-12-31 09:12:41 +00:00
|
|
|
description = "Optimised synchronisation of LVM snapshots over a network";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://theshed.hezmatt.org/lvmsync/";
|
2017-12-31 09:12:41 +00:00
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.all;
|
2019-07-22 12:02:47 +00:00
|
|
|
maintainers = with maintainers; [ jluttine nicknovitski ];
|
2017-12-31 09:12:41 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|