3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/tools/open-policy-agent/default.nix

29 lines
705 B
Nix
Raw Normal View History

2019-11-08 12:47:13 +00:00
{ lib, buildGoPackage, fetchFromGitHub }:
buildGoPackage rec {
pname = "open-policy-agent";
2020-08-07 20:33:52 +01:00
version = "0.22.0";
2019-11-08 12:47:13 +00:00
goPackagePath = "github.com/open-policy-agent/opa";
src = fetchFromGitHub {
owner = "open-policy-agent";
repo = "opa";
rev = "v${version}";
2020-08-07 20:33:52 +01:00
sha256 = "1kndiiqf6b4j8zhv0ypjr9dfjgck25qiqa2bb0pmpm3j9460zzjs";
2019-11-08 12:47:13 +00:00
};
goDeps = ./deps.nix;
buildFlagsArray = ''
-ldflags=
-X ${goPackagePath}/version.Version=${version}
'';
2019-11-08 12:47:13 +00:00
meta = with lib; {
description = "General-purpose policy engine";
homepage = "https://www.openpolicyagent.org";
license = licenses.asl20;
maintainers = with maintainers; [ lewo ];
platforms = platforms.all;
};
}