1{
2 lib,
3 buildGoModule,
4 fetchFromGitHub,
5 makeBinaryWrapper,
6}:
7
8buildGoModule rec {
9 pname = "cloud-nuke";
10 version = "0.41.0";
11
12 src = fetchFromGitHub {
13 owner = "gruntwork-io";
14 repo = "cloud-nuke";
15 tag = "v${version}";
16 hash = "sha256-OYk43yR4QFIiCOBCro1uy91SI+9fuMZ2m9h1lbz4R8Y=";
17 };
18
19 vendorHash = "sha256-4rMcbCBRZYbSJosS1VMPZ96caxwaKs5CwFGUfv7O40g=";
20
21 nativeBuildInputs = [
22 makeBinaryWrapper
23 ];
24
25 ldflags = [
26 "-s"
27 "-w"
28 "-X=main.VERSION=${version}"
29 ];
30
31 doCheck = false;
32
33 postInstall = ''
34 wrapProgram $out/bin/cloud-nuke --set-default DISABLE_TELEMETRY true
35 '';
36
37 meta = {
38 homepage = "https://github.com/gruntwork-io/cloud-nuke";
39 description = "Tool for cleaning up your cloud accounts by nuking (deleting) all resources within it";
40 mainProgram = "cloud-nuke";
41 changelog = "https://github.com/gruntwork-io/cloud-nuke/releases/tag/v${version}";
42 license = lib.licenses.mit;
43 maintainers = with lib.maintainers; [ ];
44 };
45}