summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArtturin <Artturin@artturin.com>2021-06-03 19:31:57 +0300
committergithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2021-06-05 19:53:06 +0000
commitb4a822688bb119a1e2612d58faa6dfbfb82a0bfb (patch)
treeb48537d0b368f8aeb695796d3a62ea6370972242
parentMerge pull request #125621 from etu/backport-php-upgrades (diff)
downloadnixpkgs-b4a822688bb119a1e2612d58faa6dfbfb82a0bfb.tar.gz
earthly: add missing buildFlags and tags
(cherry picked from commit a5bf3427fbd1faeb979fca80da54c51bfbb2948c)
-rw-r--r--pkgs/development/tools/earthly/default.nix13
1 files changed, 13 insertions, 0 deletions
diff --git a/pkgs/development/tools/earthly/default.nix b/pkgs/development/tools/earthly/default.nix
index 68a8d1d03523..ed3ffa3eaa3f 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