Skip to content

Instantly share code, notes, and snippets.

@jnetod
Forked from bryanasdev000/default.nix
Last active June 16, 2021 20:24
Show Gist options
  • Save jnetod/a882c653e933e53c8dfbb8f9cad696bb to your computer and use it in GitHub Desktop.
Save jnetod/a882c653e933e53c8dfbb8f9cad696bb to your computer and use it in GitHub Desktop.
Trying to build Linkerd...
{ lib, fetchFromGitHub, buildGoModule }:
buildGoModule rec {
pname = "linkerd";
version = "2.10.2";
src = fetchFromGitHub {
owner = "linkerd";
repo = "linkerd2";
rev = "stable-${version}";
sha256 = "sha256-dOD0S4FJ2lXE+1VZooi8tKvC8ndGEHAxmAvSqoWI/m0=";
};
preBuild = ''
env GOFLAGS="" go generate ./pkg/charts/static
env GOFLAGS="" go generate ./jaeger/static
env GOFLAGS="" go generate ./multicluster/static
env GOFLAGS="" go generate ./viz/static
'';
buildFlagsArray = [
"-tags=prod"
];
ldflags = [
"-s" "-w"
"-X github.com/linkerd/linkerd2/pkg/version.Version=${src.rev}"
];
vendorSha256 = "sha256-Qb0FZOvKL9GgncfUl538PynkYbm3V8Q6lUpApUoIp5s=";
doCheck = true;
runVend = true;
subPackages = [ "cli" ];
meta = with lib; {
description = "A service mesh for Kubernetes and beyond";
homepage = "https://linkerd.io/";
license = licenses.asl20;
maintainers = with maintainers; [ Gonzih bryanasdev000 ];
};
}
@superherointj
Copy link

Solution at: NixOS/nixpkgs#127130

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment