nixpkgs/pkgs/applications/networking/cluster/hubble/default.nix

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

49 lines
1.5 KiB
Nix
Raw Normal View History

{ stdenv, lib, buildGoModule, fetchFromGitHub, installShellFiles }:
2021-09-12 13:30:42 +00:00
buildGoModule rec {
pname = "hubble";
version = "0.10.0";
2021-09-12 13:30:42 +00:00
src = fetchFromGitHub {
owner = "cilium";
repo = pname;
rev = "v${version}";
2021-12-06 05:56:11 +00:00
sha256 = "sha256-L8sRvIA89RiXjrG0WcH72iYKlNTFvmQrveA9k5EBRKo=";
2021-09-12 13:30:42 +00:00
};
vendorSha256 = null;
ldflags = [
"-s" "-w"
"-X github.com/cilium/hubble/pkg.GitBranch=none"
"-X github.com/cilium/hubble/pkg.GitHash=none"
"-X github.com/cilium/hubble/pkg.Version=${version}"
];
# Test fails at Test_getFlowsRequestWithInvalidRawFilters in github.com/cilium/hubble/cmd/observe
# https://github.com/NixOS/nixpkgs/issues/178976
# https://github.com/cilium/hubble/pull/656
# https://github.com/cilium/hubble/pull/655
doCheck = false;
doInstallCheck = true;
installCheckPhase = ''
$out/bin/hubble version | grep ${version} > /dev/null
'';
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd hubble \
--bash <($out/bin/hubble completion bash) \
--fish <($out/bin/hubble completion fish) \
--zsh <($out/bin/hubble completion zsh)
'';
2021-09-12 13:30:42 +00:00
meta = with lib; {
broken = (stdenv.isLinux && stdenv.isAarch64) || stdenv.isDarwin;
2021-09-12 13:30:42 +00:00
description = "Network, Service & Security Observability for Kubernetes using eBPF";
license = licenses.asl20;
homepage = "https://github.com/cilium/hubble/";
maintainers = with maintainers; [ humancalico bryanasdev000 ];
2021-09-12 13:30:42 +00:00
};
}