60 lines
1.3 KiB
Nix
60 lines
1.3 KiB
Nix
|
|
{
|
||
|
|
lib,
|
||
|
|
stdenv,
|
||
|
|
buildGoModule,
|
||
|
|
fetchFromGitHub,
|
||
|
|
installShellFiles,
|
||
|
|
}:
|
||
|
|
|
||
|
|
buildGoModule rec {
|
||
|
|
pname = "eksctl";
|
||
|
|
version = "0.214.0";
|
||
|
|
|
||
|
|
src = fetchFromGitHub {
|
||
|
|
owner = "weaveworks";
|
||
|
|
repo = "eksctl";
|
||
|
|
rev = version;
|
||
|
|
hash = "sha256-JsVW1JC3VdxCJpngPCkrIbH5B/YlAKOc/SOIEo7s8mo=";
|
||
|
|
};
|
||
|
|
|
||
|
|
vendorHash = "sha256-0tdhi2uqC1aIK9Nkfr9OuV0mCWiT0sNX1W3hgz1vslU=";
|
||
|
|
|
||
|
|
doCheck = false;
|
||
|
|
|
||
|
|
subPackages = [ "cmd/eksctl" ];
|
||
|
|
|
||
|
|
tags = [
|
||
|
|
"netgo"
|
||
|
|
"release"
|
||
|
|
];
|
||
|
|
|
||
|
|
ldflags = [
|
||
|
|
"-s"
|
||
|
|
"-w"
|
||
|
|
"-X github.com/weaveworks/eksctl/pkg/version.gitCommit=${src.rev}"
|
||
|
|
"-X github.com/weaveworks/eksctl/pkg/version.buildDate=19700101-00:00:00"
|
||
|
|
];
|
||
|
|
|
||
|
|
nativeBuildInputs = [ installShellFiles ];
|
||
|
|
|
||
|
|
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
|
||
|
|
installShellCompletion --cmd eksctl \
|
||
|
|
--bash <($out/bin/eksctl completion bash) \
|
||
|
|
--fish <($out/bin/eksctl completion fish) \
|
||
|
|
--zsh <($out/bin/eksctl completion zsh)
|
||
|
|
'';
|
||
|
|
|
||
|
|
meta = {
|
||
|
|
description = "CLI for Amazon EKS";
|
||
|
|
homepage = "https://github.com/weaveworks/eksctl";
|
||
|
|
changelog = "https://github.com/eksctl-io/eksctl/releases/tag/v${version}";
|
||
|
|
license = lib.licenses.asl20;
|
||
|
|
maintainers = with lib.maintainers; [
|
||
|
|
xrelkd
|
||
|
|
Chili-Man
|
||
|
|
ryan4yin
|
||
|
|
];
|
||
|
|
mainProgram = "eksctl";
|
||
|
|
};
|
||
|
|
}
|