2021-01-31 01:03:55 +01:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, nixosTests }:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "artifactory_exporter";
|
2021-05-11 05:28:40 +02:00
|
|
|
version = "1.9.1";
|
2021-01-31 01:03:55 +01:00
|
|
|
rev = "v${version}";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "peimanja";
|
|
|
|
repo = pname;
|
|
|
|
rev = rev;
|
2021-05-11 05:28:40 +02:00
|
|
|
sha256 = "1m68isplrs3zvkg0mans9bgablsif6264x3w475bpnhf68r87v1q";
|
2021-01-31 01:03:55 +01:00
|
|
|
};
|
|
|
|
|
2021-05-11 05:28:40 +02:00
|
|
|
vendorSha256 = "0acwgb0h89parkx75jp057m2hrqyd95vr2zcfqnxbnyy98gxip73";
|
2021-01-31 01:03:55 +01:00
|
|
|
|
|
|
|
subPackages = [ "." ];
|
|
|
|
|
2021-08-26 08:45:51 +02:00
|
|
|
ldflags = [
|
|
|
|
"-s" "-w"
|
|
|
|
"-X github.com/prometheus/common/version.Version=${version}"
|
|
|
|
"-X github.com/prometheus/common/version.Revision=${rev}"
|
|
|
|
"-X github.com/prometheus/common/version.Branch=master"
|
|
|
|
"-X github.com/prometheus/common/version.BuildDate=19700101-00:00:00"
|
|
|
|
];
|
2021-01-31 01:03:55 +01:00
|
|
|
|
|
|
|
passthru.tests = { inherit (nixosTests.prometheus-exporters) artifactory; };
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "JFrog Artifactory Prometheus Exporter";
|
|
|
|
homepage = "https://github.com/peimanja/artifactory_exporter";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ lbpdt ];
|
|
|
|
};
|
|
|
|
}
|