2022-09-09 14:08:57 +00:00
|
|
|
{ buildGoModule
|
|
|
|
, clickhouse-backup
|
|
|
|
, fetchFromGitHub
|
|
|
|
, lib
|
|
|
|
, testers
|
|
|
|
}:
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "clickhouse-backup";
|
2022-10-30 15:09:59 +00:00
|
|
|
version = "2.1.2";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "AlexAkulov";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-10-30 15:09:59 +00:00
|
|
|
sha256 = "sha256-Vc9zPERRF6AWSOGSiOe6n33Ioc3uOtHQEehfMhPkSFk=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
vendorSha256 = "sha256-kbIztD0g+92gxxBYhWILudgFRFCshagmAUs8bY/Z8yg=";
|
2022-09-09 14:08:57 +00:00
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-X main.version=${version}"
|
|
|
|
];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
postConfigure = ''
|
|
|
|
export CGO_ENABLED=0
|
|
|
|
'';
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
|
|
|
package = clickhouse-backup;
|
|
|
|
};
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Tool for easy ClickHouse backup and restore with cloud storages support";
|
2022-09-09 14:08:57 +00:00
|
|
|
homepage = "https://github.com/AlexAkulov/clickhouse-backup";
|
2021-12-06 16:07:01 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ ma27 ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|