depot/third_party/nixpkgs/pkgs/by-name/pr/prometheus-jmx-javaagent/package.nix
Default email bcb2f287e1 Project import generated by Copybara.
GitOrigin-RevId: d603719ec6e294f034936c0d0dc06f689d91b6c3
2024-06-20 20:27:18 +05:30

36 lines
907 B
Nix

{
lib,
stdenv,
fetchurl,
}:
stdenv.mkDerivation (
finalAttrs:
let
jarName = "jmx_prometheus_javaagent-${finalAttrs.version}.jar";
in
{
pname = "jmx-prometheus-javaagent";
version = "0.20.0";
src = fetchurl {
url = "mirror://maven/io/prometheus/jmx/jmx_prometheus_javaagent/${finalAttrs.version}/${jarName}";
sha256 = "sha256-i2ftQEhdR1ZIw20R0hRktIRAb4X6+RKzNj9xpqeGEyA=";
};
dontUnpack = true;
installPhase = ''
env
mkdir -p $out/lib
cp $src $out/lib/${jarName}
'';
meta = {
homepage = "https://github.com/prometheus/jmx_exporter";
description = "A process for exposing JMX Beans via HTTP for Prometheus consumption";
sourceProvenance = [ lib.sourceTypes.binaryBytecode ];
license = lib.licenses.asl20;
maintainers = [ lib.maintainers.srhb ];
platforms = lib.platforms.unix;
};
}
)