11 rustPlatform.buildRustPackage rec {
12 pname = "wireguard-exporter";
15 src = fetchFromGitHub {
17 repo = "prometheus_wireguard_exporter";
19 sha256 = "sha256-2e31ZuGJvpvu7L2Lb+n6bZWpC1JhETzEzSiNaxxsAtA=";
22 cargoHash = "sha256-NsxGpjuZPpz4gCJRp5IOcfRFh8DTud47nV2bE0/kc2Q=";
25 # drop hardcoded linker names, fixing static build
29 buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
34 passthru.tests = { inherit (nixosTests.prometheus-exporters) wireguard; };
37 description = "Prometheus exporter for WireGuard, written in Rust";
38 homepage = "https://github.com/MindFlavor/prometheus_wireguard_exporter";
39 license = licenses.mit;
40 maintainers = with maintainers; [
44 mainProgram = "prometheus_wireguard_exporter";