2023-05-30 08:32:27 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, stdenv }:
|
2021-05-02 16:30:24 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "earthly";
|
2023-06-09 03:15:33 +00:00
|
|
|
version = "0.7.8";
|
2021-05-02 16:30:24 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "earthly";
|
|
|
|
repo = "earthly";
|
|
|
|
rev = "v${version}";
|
2023-06-09 03:15:33 +00:00
|
|
|
sha256 = "sha256-zLv0wuAM6d84Z2jCf89KDIIqX+Hiiw40g3DnTZxVTYY=";
|
2021-05-02 16:30:24 +00:00
|
|
|
};
|
|
|
|
|
2023-06-09 03:15:33 +00:00
|
|
|
vendorHash = "sha256-NUm+vkJsT78pxrPqwDofPlrc6jQMTFjsRF7uPUPhDGQ=";
|
2023-05-30 08:32:27 +00:00
|
|
|
subPackages = [ "cmd/earthly" "cmd/debugger" ];
|
|
|
|
|
|
|
|
CGO_ENABLED = 0;
|
2021-05-02 16:30:24 +00:00
|
|
|
|
2021-08-26 06:45:51 +00:00
|
|
|
ldflags = [
|
2023-05-30 08:32:27 +00:00
|
|
|
"-s"
|
|
|
|
"-w"
|
2021-08-26 06:45:51 +00:00
|
|
|
"-X main.Version=v${version}"
|
2023-05-30 08:32:27 +00:00
|
|
|
"-X main.DefaultBuildkitdImage=docker.io/earthly/buildkitd:v${version}"
|
|
|
|
"-X main.GitSha=v${version}"
|
|
|
|
"-X main.DefaultInstallationName=earthly"
|
|
|
|
] ++ lib.optionals stdenv.isLinux [
|
|
|
|
"-extldflags '-static'"
|
2021-08-26 06:45:51 +00:00
|
|
|
];
|
2021-06-03 16:31:57 +00:00
|
|
|
|
2023-05-30 08:32:27 +00:00
|
|
|
tags = [
|
|
|
|
"dfrunmount"
|
|
|
|
"dfrunnetwork"
|
|
|
|
"dfrunsecurity"
|
|
|
|
"dfsecrets"
|
|
|
|
"dfssh"
|
|
|
|
];
|
2021-10-24 15:31:27 +00:00
|
|
|
|
2021-05-02 16:30:24 +00:00
|
|
|
postInstall = ''
|
|
|
|
mv $out/bin/debugger $out/bin/earthly-debugger
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Build automation for the container era";
|
|
|
|
homepage = "https://earthly.dev/";
|
|
|
|
changelog = "https://github.com/earthly/earthly/releases/tag/v${version}";
|
2022-05-06 16:00:53 +00:00
|
|
|
license = licenses.mpl20;
|
2023-05-30 08:32:27 +00:00
|
|
|
maintainers = with maintainers; [ zoedsoupe konradmalik ];
|
2021-05-02 16:30:24 +00:00
|
|
|
};
|
|
|
|
}
|