3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/tools/backup/duplicati/default.nix

38 lines
1.4 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchzip, mono, sqlite, makeWrapper }:
2018-04-07 18:42:38 +01:00
stdenv.mkDerivation rec {
pname = "duplicati";
version = "2.0.6.1";
2018-04-07 18:42:38 +01:00
channel = "beta";
build_date = "2021-05-03";
2018-04-07 18:42:38 +01:00
src = fetchzip {
url = "https://github.com/duplicati/duplicati/releases/download/v${version}-${version}_${channel}_${build_date}/duplicati-${version}_${channel}_${build_date}.zip";
sha256 = "09537hswpicsx47vfdm78j3h7vvjd7nqjd2461jrln57nl7v7dac";
2018-04-07 18:42:38 +01:00
stripRoot = false;
};
nativeBuildInputs = [ makeWrapper ];
2018-04-07 18:42:38 +01:00
installPhase = ''
mkdir -p $out/{bin,share/${pname}-${version}}
cp -r * $out/share/${pname}-${version}
2018-04-07 18:42:38 +01:00
makeWrapper "${mono}/bin/mono" $out/bin/duplicati-cli \
--add-flags "$out/share/${pname}-${version}/Duplicati.CommandLine.exe" \
2021-01-15 09:19:50 +00:00
--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [
2018-04-07 18:42:38 +01:00
sqlite ]}
makeWrapper "${mono}/bin/mono" $out/bin/duplicati-server \
--add-flags "$out/share/${pname}-${version}/Duplicati.Server.exe" \
2021-01-15 09:19:50 +00:00
--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [
2018-04-07 18:42:38 +01:00
sqlite ]}
'';
meta = with lib; {
2018-04-07 18:42:38 +01:00
description = "A free backup client that securely stores encrypted, incremental, compressed backups on cloud storage services and remote file servers";
homepage = "https://www.duplicati.com/";
2018-04-07 18:42:38 +01:00
license = licenses.lgpl21;
maintainers = with maintainers; [ nyanloutre ];
platforms = platforms.all;
};
}