diff options
author | Alyssa Ross <hi@alyssa.is> | 2021-08-04 10:43:07 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2021-08-04 10:43:07 +0000 |
commit | 62614cbef7da005c1eda8c9400160f6bcd6546b8 (patch) | |
tree | c2630f69080637987b68acb1ee8676d2681fe304 /pkgs/development/tools/dockle | |
parent | d9c82ed3044c72cecf01c6ea042489d30914577c (diff) | |
parent | e24069138dfec3ef94f211f1da005bb5395adc11 (diff) | |
download | nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar.gz nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar.bz2 nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar.lz nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar.xz nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.tar.zst nixpkgs-62614cbef7da005c1eda8c9400160f6bcd6546b8.zip |
Merge branch 'nixpkgs-update' into master
Diffstat (limited to 'pkgs/development/tools/dockle')
-rw-r--r-- | pkgs/development/tools/dockle/default.nix | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/pkgs/development/tools/dockle/default.nix b/pkgs/development/tools/dockle/default.nix new file mode 100644 index 00000000000..437f7f2da58 --- /dev/null +++ b/pkgs/development/tools/dockle/default.nix @@ -0,0 +1,48 @@ +{ lib, buildGoModule, fetchFromGitHub, pkg-config, btrfs-progs, lvm2 }: + +buildGoModule rec { + pname = "dockle"; + version = "0.3.15"; + + src = fetchFromGitHub { + owner = "goodwithtech"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-jxFlbGJ95cSv08HcqrVufpTE5KkvAC9zOTQ2+JZWe5A="; + }; + + vendorSha256 = "sha256-h+2AcppNUJ7zjHeBzDy1iWoR3i7a2v0Pc7vOfoUqPOw="; + + nativeBuildInputs = [ pkg-config ]; + buildInputs = [ btrfs-progs lvm2 ]; + + preBuild = '' + buildFlagsArray+=("-ldflags" "-s -w -X main.version=${version}") + ''; + + preCheck = '' + # Remove tests that use networking + rm pkg/scanner/scan_test.go + ''; + + doInstallCheck = true; + installCheckPhase = '' + runHook preInstallCheck + $out/bin/dockle --help + $out/bin/dockle --version | grep "dockle version ${version}" + runHook postInstallCheck + ''; + + meta = with lib; { + homepage = "https://containers.goodwith.tech"; + changelog = "https://github.com/goodwithtech/dockle/releases/tag/v${version}"; + description = "Container Image Linter for Security"; + longDescription = '' + Container Image Linter for Security. + Helping build the Best-Practice Docker Image. + Easy to start. + ''; + license = licenses.asl20; + maintainers = with maintainers; [ jk ]; + }; +} |