2021-12-06 16:07:01 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, kubernetes-helm }:
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "telepresence2";
|
2022-04-15 01:41:22 +00:00
|
|
|
version = "2.5.4";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "telepresenceio";
|
|
|
|
repo = "telepresence";
|
|
|
|
rev = "v${version}";
|
2022-04-15 01:41:22 +00:00
|
|
|
sha256 = "sha256-v6E1v89cVL4N8eKJ5pKU6BwQWZF5lLs4VLGhUS5J1rA=";
|
2021-05-20 23:08:51 +00:00
|
|
|
};
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
# The Helm chart is go:embed'ed as a tarball in the binary.
|
|
|
|
# That tarball is generated by running ./build-aux/package_embedded_chart/main.go,
|
|
|
|
# which tries to invoke helm from tools/bin/helm.
|
|
|
|
# Oh well…
|
|
|
|
preBuild = ''
|
|
|
|
mkdir -p tools/bin
|
|
|
|
ln -sfn ${kubernetes-helm}/bin/helm tools/bin/helm
|
|
|
|
go run ./build-aux/package_embedded_chart/main.go ${src.rev}
|
|
|
|
'';
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
vendorSha256 = "sha256-RDXP7faijMujAV19l9NmI4xk0Js6DE5YZoHRo2GHyoU=";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
2021-08-27 14:25:00 +00:00
|
|
|
ldflags = [
|
|
|
|
"-s" "-w" "-X=github.com/telepresenceio/telepresence/v2/pkg/version.Version=${src.rev}"
|
|
|
|
];
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
subPackages = [ "cmd/telepresence" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Local development against a remote Kubernetes or OpenShift cluster";
|
|
|
|
homepage = "https://www.getambassador.io/docs/telepresence/2.1/quick-start/";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ mausch ];
|
2022-04-27 09:35:20 +00:00
|
|
|
mainProgram = "telepresence";
|
2021-05-20 23:08:51 +00:00
|
|
|
};
|
|
|
|
}
|