2022-05-14 08:18:31 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, nixosTests }:
|
2016-06-05 13:42:10 +00:00
|
|
|
|
2022-05-14 08:18:31 +00:00
|
|
|
buildGoModule rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "nginx_exporter";
|
2022-05-14 08:18:31 +00:00
|
|
|
version = "0.10.0";
|
2016-06-05 13:42:10 +00:00
|
|
|
|
2018-05-01 12:31:48 +00:00
|
|
|
src = fetchFromGitHub {
|
2019-07-17 12:35:07 +00:00
|
|
|
owner = "nginxinc";
|
|
|
|
repo = "nginx-prometheus-exporter";
|
2022-05-14 08:18:31 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "sha256-k9sbMIn5N3EJ7ZlfmD9pRV6lfywnKyFvpxC/pGGgNTA=";
|
2016-06-05 13:42:10 +00:00
|
|
|
};
|
|
|
|
|
2022-05-14 08:18:31 +00:00
|
|
|
vendorSha256 = "sha256-SaaHbn97cb/d8symyrBYLzK+5ukVLfGrFiRIz+tKPhw=";
|
|
|
|
|
|
|
|
ldflags = [ "-s" "-w" "-X main.version=${version}" ];
|
2019-08-11 10:30:04 +00:00
|
|
|
|
2020-06-18 10:48:40 +00:00
|
|
|
passthru.tests = { inherit (nixosTests.prometheus-exporters) nginx; };
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-07-17 12:35:07 +00:00
|
|
|
description = "NGINX Prometheus Exporter for NGINX and NGINX Plus";
|
|
|
|
homepage = "https://github.com/nginxinc/nginx-prometheus-exporter";
|
|
|
|
license = licenses.asl20;
|
2019-08-20 17:36:05 +00:00
|
|
|
maintainers = with maintainers; [ benley fpletz willibutz globin ];
|
2016-06-05 13:42:10 +00:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|