Merge pull request #330634 from r-ryantm/auto-update/circumflex
[NixPkgs.git] / pkgs / servers / monitoring / prometheus / pushgateway.nix
blobcc8e11ade635513faa42ac63b1fe0023f68dedac
1 { lib, buildGoModule, fetchFromGitHub, nixosTests, testers, prometheus-pushgateway }:
3 buildGoModule rec {
4   pname = "pushgateway";
5   version = "1.9.0";
7   src = fetchFromGitHub {
8     owner = "prometheus";
9     repo = "pushgateway";
10     rev = "v${version}";
11     sha256 = "sha256-SpHxBxBl0APP/y7MnR/p/+VjNAvFOZVlgGMlMGTbodI=";
12   };
14   vendorHash = "sha256-GydAY73Ui6z833x0DoWa6BpK35CYdYfyHw2+RwT3miw=";
16   ldflags = [
17     "-s"
18     "-w"
19     "-X github.com/prometheus/common/version.Version=${version}"
20     "-X github.com/prometheus/common/version.Revision=${version}"
21     "-X github.com/prometheus/common/version.Branch=${version}"
22     "-X github.com/prometheus/common/version.BuildUser=nix@nixpkgs"
23     "-X github.com/prometheus/common/version.BuildDate=19700101-00:00:00"
24   ];
26   passthru.tests = {
27     inherit (nixosTests.prometheus) pushgateway;
28     version = testers.testVersion {
29       package = prometheus-pushgateway;
30     };
31   };
33   meta = with lib; {
34     description = "Allows ephemeral and batch jobs to expose metrics to Prometheus";
35     mainProgram = "pushgateway";
36     homepage = "https://github.com/prometheus/pushgateway";
37     license = licenses.asl20;
38     maintainers = with maintainers; [ benley ];
39   };