2022-10-06 18:32:54 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, testers, prometheus-pushgateway }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
buildGoModule rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "pushgateway";
|
2023-07-15 17:15:38 +00:00
|
|
|
version = "1.6.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "prometheus";
|
|
|
|
repo = "pushgateway";
|
2022-10-06 18:32:54 +00:00
|
|
|
rev = "v${version}";
|
2023-07-15 17:15:38 +00:00
|
|
|
sha256 = "sha256-sJ4TTyo+A3CEUcTJv3LlUU60pc/a/PgB0Mk6R5wpTgM=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
vendorHash = "sha256-oDvFp7FYam/hsiEesfTuNgXciH4JAUKkMiECn4FPqmE=";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-27 14:25:00 +00:00
|
|
|
ldflags = [
|
2022-10-06 18:32:54 +00:00
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X github.com/prometheus/common/version.Version=${version}"
|
|
|
|
"-X github.com/prometheus/common/version.Revision=${version}"
|
|
|
|
"-X github.com/prometheus/common/version.Branch=${version}"
|
|
|
|
"-X github.com/prometheus/common/version.BuildUser=nix@nixpkgs"
|
|
|
|
"-X github.com/prometheus/common/version.BuildDate=19700101-00:00:00"
|
2021-08-27 14:25:00 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
|
|
|
package = prometheus-pushgateway;
|
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Allows ephemeral and batch jobs to expose metrics to Prometheus";
|
|
|
|
homepage = "https://github.com/prometheus/pushgateway";
|
|
|
|
license = licenses.asl20;
|
2022-08-12 12:06:08 +00:00
|
|
|
maintainers = with maintainers; [ benley ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|