From b4a822688bb119a1e2612d58faa6dfbfb82a0bfb Mon Sep 17 00:00:00 2001 From: Artturin Date: Thu, 3 Jun 2021 19:31:57 +0300 Subject: [PATCH] earthly: add missing buildFlags and tags (cherry picked from commit a5bf3427fbd1faeb979fca80da54c51bfbb2948c) --- pkgs/development/tools/earthly/default.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/pkgs/development/tools/earthly/default.nix b/pkgs/development/tools/earthly/default.nix index 68a8d1d0352..ed3ffa3eaa3 100644 --- a/pkgs/development/tools/earthly/default.nix +++ b/pkgs/development/tools/earthly/default.nix @@ -13,6 +13,19 @@ buildGoModule rec { vendorSha256 = "sha256-q3dDV0eop2NxXHFrlppWsZrO2Hz1q5xhs1DnB6PvG9g="; + buildFlagsArray = '' + -ldflags= + -s -w + -X main.Version=v${version} + -X main.DefaultBuildkitdImage=earthly/buildkitd:v${version} + -extldflags -static + ''; + + BUILDTAGS = "dfrunmount dfrunsecurity dfsecrets dfssh dfrunnetwork"; + preBuild = '' + makeFlagsArray+=(BUILD_TAGS="${BUILDTAGS}") + ''; + postInstall = '' mv $out/bin/debugger $out/bin/earthly-debugger mv $out/bin/shellrepeater $out/bin/earthly-shellrepeater