forked from mirrors/nixpkgs
cosign: 1.5.2 -> 1.6.0
Co-authored-by: Thomas Gerbet <thomas@gerbet.me>
This commit is contained in:
parent
7e047125d1
commit
b489e63c3c
|
@ -2,13 +2,13 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "cosign";
|
||||
version = "1.5.2";
|
||||
version = "1.6.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "sigstore";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-37jahAGgQn7HwwdRTlAS/oJQ3BxTkMViI6iJMBYFgjI=";
|
||||
sha256 = "sha256-jAkTIO+tmb1vjS2eRWU9Fau7qzPCBlXJCk00iwNpULE=";
|
||||
};
|
||||
|
||||
buildInputs = lib.optional (stdenv.isLinux && pivKeySupport) (lib.getDev pcsclite)
|
||||
|
@ -16,19 +16,36 @@ buildGoModule rec {
|
|||
|
||||
nativeBuildInputs = [ pkg-config installShellFiles ];
|
||||
|
||||
vendorSha256 = "sha256-d3aOX4iMlhlxgYbqCHCIFKXunVha0Fw4ZBmy4OA6EhI=";
|
||||
vendorSha256 = "sha256-E9zeRlPIIoXo/EfagHC3aDnW747SdsPiqIA384D7NQI=";
|
||||
|
||||
excludedPackages = "\\(sample\\|webhook\\|help\\)";
|
||||
subPackages = [
|
||||
"cmd/cosign"
|
||||
"cmd/cosign/webhook"
|
||||
"cmd/sget"
|
||||
];
|
||||
|
||||
tags = [] ++ lib.optionals pivKeySupport [ "pivkey" ] ++ lib.optionals pkcs11Support [ "pkcs11key" ];
|
||||
|
||||
ldflags = [ "-s" "-w" "-X github.com/sigstore/cosign/pkg/version.GitVersion=v${version}" ];
|
||||
ldflags = [
|
||||
"-s"
|
||||
"-w"
|
||||
"-X sigs.k8s.io/release-utils/version.gitVersion=v${version}"
|
||||
"-X sigs.k8s.io/release-utils/version.gitTreeState=clean"
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
rm pkg/cosign/tuf/client_test.go # Require network access
|
||||
rm internal/pkg/cosign/fulcio/signer_test.go # Require network access
|
||||
rm internal/pkg/cosign/rekor/signer_test.go # Require network access
|
||||
postBuild = ''
|
||||
# cmd/cosign/webhook should be called cosigned
|
||||
mv $GOPATH/bin/{webhook,cosigned}
|
||||
'';
|
||||
|
||||
preCheck = ''
|
||||
# test all paths
|
||||
unset subPackages
|
||||
|
||||
rm cmd/cosign/cli/fulcio/fulcioroots/fulcioroots_test.go # Require network access
|
||||
rm pkg/cosign/kubernetes/webhook/validator_test.go # Require network access
|
||||
rm pkg/cosign/tlog_test.go # Require network access
|
||||
rm pkg/cosign/tuf/client_test.go # Require network access
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
|
|
Loading…
Reference in a new issue