mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
41 lines
939 B
Nix
41 lines
939 B
Nix
{
|
|
lib,
|
|
buildGoModule,
|
|
fetchFromGitHub,
|
|
versionCheckHook,
|
|
}:
|
|
|
|
buildGoModule (finalAttrs: {
|
|
pname = "brutus";
|
|
version = "1.4.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "praetorian-inc";
|
|
repo = "brutus";
|
|
tag = "v${finalAttrs.version}";
|
|
hash = "sha256-1UuxEYhMNyzBTqRzObwsq4Kb4hQG/yU/V8AxA3jrqAw=";
|
|
};
|
|
|
|
vendorHash = "sha256-vG4Ld0OTxVk/qnEiACgNXTGq4kt1yjaLIneZ2KbEGpg=";
|
|
|
|
ldflags = [
|
|
"-s"
|
|
"-X=main.Version=${finalAttrs.version}"
|
|
"-X=main.BuildTime=1970-01-01T00:00:00Z"
|
|
"-X=main.CommitSHA=${finalAttrs.src.rev}"
|
|
];
|
|
|
|
nativeInstallCheckInputs = [ versionCheckHook ];
|
|
|
|
doInstallCheck = true;
|
|
|
|
versionCheckProgramArg = [ "--version" ];
|
|
|
|
meta = {
|
|
description = "Credential testing tool for multiple services";
|
|
homepage = "https://github.com/praetorian-inc/brutus";
|
|
license = lib.licenses.asl20;
|
|
maintainers = with lib.maintainers; [ fab ];
|
|
mainProgram = "brutus";
|
|
};
|
|
})
|