depot/third_party/nixpkgs/pkgs/by-name/pr/prometheus-jmx-javaagent/package.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

36 lines
906 B
Nix

{
lib,
stdenv,
fetchurl,
}:
stdenv.mkDerivation (
finalAttrs:
let
jarName = "jmx_prometheus_javaagent-${finalAttrs.version}.jar";
in
{
pname = "jmx-prometheus-javaagent";
version = "1.0.1";
src = fetchurl {
url = "mirror://maven/io/prometheus/jmx/jmx_prometheus_javaagent/${finalAttrs.version}/${jarName}";
sha256 = "sha256-fWH3N/1mFhDMwUrqeXZPqh6pSjQMvI8AKbPS7eo9gME=";
};
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;
};
}
)