2023-01-08 08:50:01 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
2024-06-29 16:21:57 +00:00
|
|
|
, go-mockery
|
2023-01-08 08:50:01 +00:00
|
|
|
}:
|
2017-01-10 07:27:30 +00:00
|
|
|
|
2020-05-06 12:05:10 +00:00
|
|
|
buildGoModule rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "terragrunt";
|
2024-11-24 20:35:27 +00:00
|
|
|
version = "0.69.1";
|
2017-01-10 07:27:30 +00:00
|
|
|
|
2020-10-16 15:18:01 +00:00
|
|
|
src = fetchFromGitHub {
|
2020-05-06 12:05:10 +00:00
|
|
|
owner = "gruntwork-io";
|
|
|
|
repo = pname;
|
2023-01-08 08:50:01 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-11-24 20:35:27 +00:00
|
|
|
hash = "sha256-/fQOrxfxZOuECp093M90KQRrCUSAqtQ5icTDTw8SM6k=";
|
2017-01-10 07:27:30 +00:00
|
|
|
};
|
|
|
|
|
2024-06-29 16:21:57 +00:00
|
|
|
nativeBuildInputs = [ go-mockery ];
|
|
|
|
|
|
|
|
preBuild = ''
|
|
|
|
make generate-mocks
|
|
|
|
'';
|
|
|
|
|
2024-11-24 20:35:27 +00:00
|
|
|
vendorHash = "sha256-HcN5TRPpKpMpy7OwM9MfRVrvw5zCbPny7X2HgY8Iu1U=";
|
2017-01-10 07:27:30 +00:00
|
|
|
|
2020-08-04 00:26:27 +00:00
|
|
|
doCheck = false;
|
|
|
|
|
2023-01-08 08:50:01 +00:00
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
2023-08-24 07:22:19 +00:00
|
|
|
"-X github.com/gruntwork-io/go-commons/version.Version=v${version}"
|
2024-11-06 10:02:48 +00:00
|
|
|
"-extldflags '-static'"
|
2023-01-08 08:50:01 +00:00
|
|
|
];
|
2017-03-15 15:01:09 +00:00
|
|
|
|
2021-02-18 21:20:05 +00:00
|
|
|
doInstallCheck = true;
|
2023-01-08 08:50:01 +00:00
|
|
|
|
2021-02-18 21:20:05 +00:00
|
|
|
installCheckPhase = ''
|
|
|
|
runHook preInstallCheck
|
|
|
|
$out/bin/terragrunt --help
|
|
|
|
$out/bin/terragrunt --version | grep "v${version}"
|
|
|
|
runHook postInstallCheck
|
|
|
|
'';
|
|
|
|
|
2020-10-23 08:48:39 +00:00
|
|
|
meta = with lib; {
|
2021-02-01 17:05:54 +00:00
|
|
|
homepage = "https://terragrunt.gruntwork.io";
|
|
|
|
changelog = "https://github.com/gruntwork-io/terragrunt/releases/tag/v${version}";
|
2020-10-11 05:55:05 +00:00
|
|
|
description = "Thin wrapper for Terraform that supports locking for Terraform state and enforces best practices";
|
2024-03-19 02:14:51 +00:00
|
|
|
mainProgram = "terragrunt";
|
2017-01-10 07:27:30 +00:00
|
|
|
license = licenses.mit;
|
2023-09-05 23:44:12 +00:00
|
|
|
maintainers = with maintainers; [ jk qjoly kashw2 ];
|
2017-01-10 07:27:30 +00:00
|
|
|
};
|
2020-07-31 03:58:04 +00:00
|
|
|
}
|