2022-06-01 16:37:17 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, installShellFiles
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "gatekeeper";
|
2024-03-13 01:05:33 +00:00
|
|
|
version = "3.15.1";
|
2022-06-01 16:37:17 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "open-policy-agent";
|
|
|
|
repo = "gatekeeper";
|
|
|
|
rev = "v${version}";
|
2024-03-13 01:05:33 +00:00
|
|
|
hash = "sha256-KPRcY14IeP4WU/cnUG7JWwJcp/LN6O74u417I+qAqXE=";
|
2022-06-01 16:37:17 +00:00
|
|
|
};
|
|
|
|
|
2023-04-19 00:48:56 +00:00
|
|
|
vendorHash = null;
|
2022-06-01 16:37:17 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
installShellFiles
|
|
|
|
];
|
|
|
|
|
|
|
|
subPackages = [ "cmd/gator" ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion --cmd gator \
|
|
|
|
--bash <($out/bin/gator completion bash) \
|
|
|
|
--fish <($out/bin/gator completion fish) \
|
|
|
|
--zsh <($out/bin/gator completion zsh)
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Policy Controller for Kubernetes";
|
|
|
|
homepage = "https://github.com/open-policy-agent/gatekeeper";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
|
|
|
};
|
|
|
|
}
|