2022-10-06 18:32:54 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, fetchpatch }:
|
2021-03-19 17:17:44 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "kubectl-doctor";
|
2022-02-20 05:27:41 +00:00
|
|
|
version = "0.3.1";
|
2021-03-19 17:17:44 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "emirozer";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-02-20 05:27:41 +00:00
|
|
|
sha256 = "sha256-yp5OfSDxIASiCgISUVNxfe3dsLukgIoHARVPALIaQfY=";
|
2021-03-19 17:17:44 +00:00
|
|
|
};
|
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
# https://github.com/emirozer/kubectl-doctor/pull/21
|
|
|
|
name = "go-1.19-client-go-0.25.patch";
|
|
|
|
url = "https://github.com/emirozer/kubectl-doctor/commit/a987ef58063e305409034af280d688a11682dbb9.patch";
|
|
|
|
sha256 = "sha256-NQd/WxUfYwBDowhnoUWaOV8k7msiOhff3Bjux+a9R9E=";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
vendorHash = "sha256-qhffg/s1RZFNW0nHLbJ89yqLzdC72ARXdbSfMLJK2pQ=";
|
2021-03-19 17:17:44 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mv $out/bin/{cmd,kubectl-doctor}
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "kubectl cluster triage plugin for k8s";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "kubectl-doctor";
|
2021-03-19 17:17:44 +00:00
|
|
|
homepage = "https://github.com/emirozer/kubectl-doctor";
|
|
|
|
changelog = "https://github.com/emirozer/kubectl-doctor/releases/tag/v${version}";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = [ maintainers.zimbatm ];
|
|
|
|
};
|
|
|
|
}
|