nixpkgs/pkgs/by-name/gl/glooctl/package.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

52 lines
1.2 KiB
Nix
Raw Normal View History

{
lib,
buildGoModule,
fetchFromGitHub,
installShellFiles,
2023-09-29 03:08:05 +00:00
}:
2022-01-04 18:40:25 +00:00
buildGoModule rec {
pname = "glooctl";
2024-10-05 20:02:22 +00:00
version = "1.17.14";
2022-01-04 18:40:25 +00:00
src = fetchFromGitHub {
owner = "solo-io";
repo = "gloo";
rev = "v${version}";
2024-10-05 20:02:22 +00:00
hash = "sha256-7KkaQYTsamUapWKPB0JIoEnOs/SvrCbBgQqvQg9VQ9o=";
2022-01-04 18:40:25 +00:00
};
2024-09-28 03:47:42 +00:00
vendorHash = "sha256-rAObw4J0ATle1gq5Z1MsrGy/iqQDHjnMPAEIPBgtY3g=";
2023-09-29 03:08:05 +00:00
2022-01-04 18:40:25 +00:00
subPackages = [ "projects/gloo/cli/cmd" ];
nativeBuildInputs = [ installShellFiles ];
2023-09-29 03:08:05 +00:00
strictDeps = true;
ldflags = [
"-s"
"-X github.com/solo-io/gloo/pkg/version.Version=${version}"
];
preCheck = ''
export HOME=$TMPDIR
'';
2022-01-04 18:40:25 +00:00
postInstall = ''
mv $out/bin/cmd $out/bin/glooctl
installShellCompletion --cmd glooctl \
--bash <($out/bin/glooctl completion bash) \
--zsh <($out/bin/glooctl completion zsh)
'';
2023-09-29 03:08:05 +00:00
meta = {
description = "Unified CLI for Gloo, the feature-rich, Kubernetes-native, next-generation API gateway built on Envoy";
mainProgram = "glooctl";
2022-01-04 18:40:25 +00:00
homepage = "https://docs.solo.io/gloo-edge/latest/reference/cli/glooctl/";
changelog = "https://github.com/solo-io/gloo/releases/tag/v${version}";
2023-09-29 03:08:05 +00:00
license = lib.licenses.asl20;
maintainers = [ ];
2022-01-04 18:40:25 +00:00
};
}