60f07311b9
GitOrigin-RevId: f8e2ebd66d097614d51a56a755450d4ae1632df1
46 lines
1.1 KiB
Nix
46 lines
1.1 KiB
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitHub
|
|
, nixosTests
|
|
, testers
|
|
, telegraf
|
|
}:
|
|
|
|
buildGoModule rec {
|
|
pname = "telegraf";
|
|
version = "1.29.4";
|
|
|
|
subPackages = [ "cmd/telegraf" ];
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "influxdata";
|
|
repo = "telegraf";
|
|
rev = "v${version}";
|
|
hash = "sha256-XhGP5q0LbXaTgClZvRFV1Zjpi1mizoyFrzI7vobVaUo=";
|
|
};
|
|
|
|
vendorHash = "sha256-DdE2r0M9/6aaq5c3m0AT82TNyIP2vBsaFCRP2um0hao=";
|
|
proxyVendor = true;
|
|
|
|
ldflags = [
|
|
"-s"
|
|
"-w"
|
|
"-X=github.com/influxdata/telegraf/internal.Commit=${src.rev}"
|
|
"-X=github.com/influxdata/telegraf/internal.Version=${version}"
|
|
];
|
|
|
|
passthru.tests = {
|
|
inherit (nixosTests) telegraf;
|
|
version = testers.testVersion {
|
|
package = telegraf;
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "The plugin-driven server agent for collecting & reporting metrics";
|
|
homepage = "https://www.influxdata.com/time-series-platform/telegraf/";
|
|
changelog = "https://github.com/influxdata/telegraf/blob/${src.rev}/CHANGELOG.md";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ mic92 roblabla timstott zowoq ];
|
|
};
|
|
}
|