{ lib, buildGoModule, fetchFromGitHub, nixosTests, }: buildGoModule rec { pname = "redis_exporter"; version = "1.66.0"; src = fetchFromGitHub { owner = "oliver006"; repo = "redis_exporter"; rev = "v${version}"; sha256 = "sha256-y+SZedMYxO0AMSjA5sCz9ynY1N537PCJ8LT3Mx1N4eA="; }; vendorHash = "sha256-b3rvF91f/JoAAY6vut+NUCbuQAf2XsQn/n5mVLPnIoU="; ldflags = [ "-X main.BuildVersion=${version}" "-X main.BuildCommitSha=unknown" "-X main.BuildDate=unknown" ]; # needs a redis server doCheck = false; passthru.tests = { inherit (nixosTests.prometheus-exporters) redis; }; meta = with lib; { description = "Prometheus exporter for Redis metrics"; mainProgram = "redis_exporter"; homepage = "https://github.com/oliver006/redis_exporter"; license = licenses.mit; maintainers = with maintainers; [ eskytthe srhb ma27 ]; }; }