nixpkgs-suyu/pkgs/tools/backup/wal-g/default.nix

36 lines
874 B
Nix
Raw Normal View History

2020-08-14 06:20:00 +02:00
{ lib, buildGoModule, fetchFromGitHub, brotli }:
buildGoModule rec {
pname = "wal-g";
version = "0.2.19";
src = fetchFromGitHub {
owner = "wal-g";
repo = "wal-g";
rev = "v${version}";
sha256 = "030c949cs13x4gnby6apy1adis8d4dlg3gzhhhs991117dxb0i3v";
2017-11-17 14:44:03 +01:00
};
vendorSha256 = "186cqn10fljzjc876byaj1affd8xmi8zvmkfxp9dbzsfxdir4nf7";
2018-11-25 09:57:22 +01:00
buildInputs = [ brotli ];
2020-02-18 10:20:00 +01:00
subPackages = [ "main/pg" ];
buildFlagsArray = [
"-tags=brotli"
"-ldflags=-s -w -X github.com/wal-g/wal-g/cmd/pg.WalgVersion=${version} -X github.com/wal-g/wal-g/cmd/pg.GitRevision=${src.rev}"
];
2020-02-18 10:20:00 +01:00
postInstall = ''
mv $out/bin/pg $out/bin/wal-g
2020-02-18 10:20:00 +01:00
'';
2020-08-14 06:20:00 +02:00
meta = with lib; {
2020-02-18 10:20:00 +01:00
homepage = "https://github.com/wal-g/wal-g";
2020-08-14 06:20:00 +02:00
license = licenses.asl20;
2020-02-18 10:20:00 +01:00
description = "An archival restoration tool for PostgreSQL";
maintainers = with maintainers; [ marsam ];
2017-11-17 14:44:03 +01:00
};
}