2021-02-05 17:12:51 +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 = "kind";
|
2024-09-19 14:19:46 +00:00
|
|
|
version = "0.24.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2024-02-29 20:09:43 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
owner = "kubernetes-sigs";
|
|
|
|
repo = "kind";
|
2024-09-19 14:19:46 +00:00
|
|
|
hash = "sha256-vndN3ssiaaJdpPZQ0vBdqr4xPuY2bAHAd+SJamNrX6Q=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-08-08 23:34:03 +00:00
|
|
|
patches = [
|
|
|
|
# fix kernel module path used by kind
|
|
|
|
./kernel-module-path.patch
|
|
|
|
];
|
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
vendorHash = "sha256-VfqNM48M39R2LaUHirKmSXCdvBXUHu09oMzDPmAQC4o=";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
subPackages = [ "." ];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
CGO_ENABLED = 0;
|
2020-08-20 17:08:02 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
ldflags = [ "-s" "-w" ];
|
2020-08-20 17:08:02 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
doCheck = false;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
2024-02-29 20:09:43 +00:00
|
|
|
installShellCompletion --cmd kind \
|
|
|
|
--bash <($out/bin/kind completion bash) \
|
|
|
|
--fish <($out/bin/kind completion fish) \
|
|
|
|
--zsh <($out/bin/kind completion zsh)
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Kubernetes IN Docker - local clusters for testing Kubernetes";
|
2024-02-29 20:09:43 +00:00
|
|
|
homepage = "https://github.com/kubernetes-sigs/kind";
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ offline rawkode ];
|
2024-02-29 20:09:43 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
mainProgram = "kind";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|