depot/third_party/nixpkgs/pkgs/servers/monitoring/mimir/default.nix
Default email 02cf88bb76 Project import generated by Copybara.
GitOrigin-RevId: c4a0efdd5a728e20791b8d8d2f26f90ac228ee8d
2022-08-12 15:06:08 +03:00

42 lines
999 B
Nix

{ lib, buildGoModule, fetchFromGitHub, nixosTests }:
buildGoModule rec {
pname = "mimir";
version = "2.2.0";
src = fetchFromGitHub {
rev = "${pname}-${version}";
owner = "grafana";
repo = pname;
sha256 = "sha256-c2WOE7lm62uZ+oVSWd2Gyo0UZJaf9yFzEQZvcwpvshA=";
};
vendorSha256 = null;
subPackages = [
"cmd/mimir"
"cmd/mimirtool"
];
passthru.tests = {
inherit (nixosTests) mimir;
};
ldflags = let t = "github.com/grafana/mimir/pkg/util/version";
in [
''-extldflags "-static"''
"-s"
"-w"
"-X ${t}.Version=${version}"
"-X ${t}.Revision=unknown"
"-X ${t}.Branch=unknown"
];
meta = with lib; {
description =
"Grafana Mimir provides horizontally scalable, highly available, multi-tenant, long-term storage for Prometheus. ";
homepage = "https://github.com/grafana/mimir";
license = licenses.agpl3Only;
maintainers = with maintainers; [ happysalada bryanhonof ];
platforms = platforms.unix;
};
}