2020-05-15 21:57:56 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, installShellFiles
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
buildGoModule rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "cri-tools";
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "1.28.0";
|
2020-05-15 21:57:56 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "kubernetes-sigs";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2023-10-09 19:29:22 +00:00
|
|
|
sha256 = "sha256-inw4bPeObMlwtgFLR/8+tqRKTkcViZeEFZ1MOm0HYI4=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
vendorHash = null;
|
2020-05-15 21:57:56 +00:00
|
|
|
|
2020-08-20 17:08:02 +00:00
|
|
|
doCheck = false;
|
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPhase = ''
|
2021-04-05 15:23:46 +00:00
|
|
|
runHook preBuild
|
2020-05-15 21:57:56 +00:00
|
|
|
make binaries VERSION=${version}
|
2021-04-05 15:23:46 +00:00
|
|
|
runHook postBuild
|
2020-05-15 21:57:56 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
2021-04-05 15:23:46 +00:00
|
|
|
runHook preInstall
|
2020-05-15 21:57:56 +00:00
|
|
|
make install BINDIR=$out/bin
|
|
|
|
|
|
|
|
for shell in bash fish zsh; do
|
|
|
|
$out/bin/crictl completion $shell > crictl.$shell
|
|
|
|
installShellCompletion crictl.$shell
|
|
|
|
done
|
2021-04-05 15:23:46 +00:00
|
|
|
runHook postInstall
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "CLI and validation tools for Kubelet Container Runtime Interface (CRI)";
|
|
|
|
homepage = "https://github.com/kubernetes-sigs/cri-tools";
|
2020-05-15 21:57:56 +00:00
|
|
|
license = licenses.asl20;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ ] ++ teams.podman.members;
|
|
|
|
};
|
|
|
|
}
|