rekor-cli, rekor-server: 0.1.1 -> 0.2.0
https://github.com/sigstore/rekor/releases/tag/v0.2.0
This commit is contained in:
parent
bb4697102b
commit
7a026e7465
1 changed files with 11 additions and 19 deletions
|
@ -1,21 +1,25 @@
|
|||
{ lib, buildGoModule, fetchFromGitHub }:
|
||||
|
||||
let
|
||||
generic = { pname, subPackages, description, postInstall }:
|
||||
generic = { pname, packageToBuild, description }:
|
||||
buildGoModule rec {
|
||||
inherit pname;
|
||||
version = "0.1.1";
|
||||
version = "0.2.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "sigstore";
|
||||
repo = "rekor";
|
||||
rev = "v${version}";
|
||||
sha256 = "1hvkfvc747g5r4h8vb1d8ikqxmlyxsycnlh78agmmjpxlasspmbk";
|
||||
sha256 = "1y6qw55r30jgkcwc6434ly0v9dcfa2lc7z5djn7rjcqrjg3gn7yv";
|
||||
};
|
||||
|
||||
vendorSha256 = "0vdir9ia3hv27rkm6jnvhsfc3mxw36xfvwqnfd34rgzmzcfxlrbv";
|
||||
vendorSha256 = "1wlh505ypwyr91wi80fpbap3far3fljwjd4mql2qcqgg0b1yay9s";
|
||||
|
||||
inherit subPackages postInstall;
|
||||
subPackages = [ packageToBuild ];
|
||||
|
||||
preBuild = ''
|
||||
buildFlagsArray+=("-ldflags" "-s -w -X github.com/sigstore/rekor/${packageToBuild}/app.gitVersion=v${version}")
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
inherit description;
|
||||
|
@ -28,24 +32,12 @@ let
|
|||
in {
|
||||
rekor-cli = generic {
|
||||
pname = "rekor-cli";
|
||||
subPackages = [ "cmd/cli" ];
|
||||
# Will not be needed with the next version, the package as been renamed upstream
|
||||
postInstall = ''
|
||||
if [ -f "$out/bin/cli" ]; then
|
||||
mv "$out/bin/cli" "$out/bin/rekor-client"
|
||||
fi
|
||||
'';
|
||||
packageToBuild = "cmd/rekor-cli";
|
||||
description = "CLI client for Sigstore, the Signature Transparency Log";
|
||||
};
|
||||
rekor-server = generic {
|
||||
pname = "rekor-server";
|
||||
subPackages = [ "cmd/server" ];
|
||||
# Will not be needed with the next version, the package as been renamed upstream
|
||||
postInstall = ''
|
||||
if [ -f "$out/bin/server" ]; then
|
||||
mv "$out/bin/server" "$out/bin/rekor-server"
|
||||
fi
|
||||
'';
|
||||
packageToBuild = "cmd/rekor-server";
|
||||
description = "Sigstore server, the Signature Transparency Log";
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue