From c94ad64ae5573f529213c4d97baf3ea67e86b6b7 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Thu, 1 Mar 2018 19:41:19 +0100 Subject: [PATCH] rsbep: init at 0.1.0 fixes #36182 --- pkgs/tools/backup/rsbep/default.nix | 37 +++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 39 insertions(+) create mode 100644 pkgs/tools/backup/rsbep/default.nix diff --git a/pkgs/tools/backup/rsbep/default.nix b/pkgs/tools/backup/rsbep/default.nix new file mode 100644 index 000000000000..96bbea4791e8 --- /dev/null +++ b/pkgs/tools/backup/rsbep/default.nix @@ -0,0 +1,37 @@ +{ stdenv, lib, coreutils, gnused, gawk, fetchurl }: + +stdenv.mkDerivation rec { + name = "rsbep-${version}"; + version = "0.1.0"; + + src = fetchurl { + url = "https://www.thanassis.space/rsbep-0.1.0-ttsiodras.tar.bz2"; + sha256 = "1zji34kc9srxp0h1s1m7k60mvgsir1wrx1n3wc990jszfplr32zc"; + }; + + postFixup = '' + cd $out/bin + + # Move internal tool 'rsbep_chopper' to libexec + libexecDir=$out/libexec/rsbep + mkdir -p $libexecDir + mv rsbep_chopper $libexecDir + + # Fix store dependencies in scripts + path="export PATH=$out/bin:$libexecDir:${lib.makeBinPath [ coreutils gnused gawk ]}" + sed -i "2i$path" freeze.sh + sed -i "2i$path" melt.sh + + substituteInPlace freeze.sh --replace /bin/ls ls + + # Remove unneded binary + rm poorZFS.py + ''; + + meta = with lib; { + description = "Create resilient backups with Reed-Solomon error correction and byte-spreading"; + homepage = https://www.thanassis.space/rsbep.html; + license = licenses.gpl3; + maintainers = [ maintainers.earvstedt ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 3d2368ed60ac..a5fe41e54b8e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1330,6 +1330,8 @@ with pkgs; riot-web = callPackage ../applications/networking/instant-messengers/riot/riot-web.nix { }; + rsbep = callPackage ../tools/backup/rsbep { }; + rsyslog = callPackage ../tools/system/rsyslog { hadoop = null; # Currently Broken czmq = czmq3;