2020-03-27 08:33:21 +01:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, makeWrapper, rpm, xz }:
|
2019-01-06 04:40:08 +01:00
|
|
|
|
2019-12-22 06:00:00 +01:00
|
|
|
buildGoModule rec {
|
2019-01-06 04:40:08 +01:00
|
|
|
pname = "clair";
|
2021-06-17 08:34:04 +02:00
|
|
|
version = "4.1.1";
|
2019-01-06 04:40:08 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2019-12-22 06:00:00 +01:00
|
|
|
owner = "quay";
|
2019-07-10 18:04:32 +02:00
|
|
|
repo = pname;
|
2019-01-06 04:40:08 +01:00
|
|
|
rev = "v${version}";
|
2021-06-17 08:34:04 +02:00
|
|
|
sha256 = "sha256-E04G3EJ0JrOVjtTd3nBHZehzuDrvt6t4hfFdGO92uuk=";
|
2019-01-06 04:40:08 +01:00
|
|
|
};
|
|
|
|
|
2021-06-17 08:34:04 +02:00
|
|
|
vendorSha256 = "sha256-xgP5IhB9eyKOIBlT5jKDJkUy8lz2UrWmGqqeDhqRawY=";
|
2019-12-22 06:00:00 +01:00
|
|
|
|
2020-08-04 02:26:27 +02:00
|
|
|
doCheck = false;
|
|
|
|
|
2019-01-06 04:40:08 +01:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
postInstall = ''
|
2019-12-22 06:00:00 +01:00
|
|
|
wrapProgram $out/bin/clair \
|
2020-03-27 08:33:21 +01:00
|
|
|
--prefix PATH : "${lib.makeBinPath [ rpm xz ]}"
|
2019-01-06 04:40:08 +01:00
|
|
|
'';
|
|
|
|
|
2020-03-27 08:33:21 +01:00
|
|
|
meta = with lib; {
|
2019-01-06 04:40:08 +01:00
|
|
|
description = "Vulnerability Static Analysis for Containers";
|
2019-12-22 06:00:00 +01:00
|
|
|
homepage = "https://github.com/quay/clair";
|
2020-12-26 05:20:00 +01:00
|
|
|
changelog = "https://github.com/quay/clair/blob/v${version}/CHANGELOG.md";
|
2019-01-06 04:40:08 +01:00
|
|
|
license = licenses.asl20;
|
2019-07-10 18:04:32 +02:00
|
|
|
maintainers = with maintainers; [ marsam ];
|
2019-01-06 04:40:08 +01:00
|
|
|
};
|
2020-07-31 05:58:04 +02:00
|
|
|
}
|