From 66be71e5ad93e89329cf19d7d3cbbcc6e2dabc99 Mon Sep 17 00:00:00 2001 From: Luis Eduardo Bueso de Barrio Date: Mon, 30 Mar 2026 14:12:20 +0200 Subject: [PATCH] fix ? --- packages/sabnzbd-mcp/package.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/sabnzbd-mcp/package.nix b/packages/sabnzbd-mcp/package.nix index 68fe310..dc0a562 100644 --- a/packages/sabnzbd-mcp/package.nix +++ b/packages/sabnzbd-mcp/package.nix @@ -29,6 +29,14 @@ stdenv.mkDerivation { nativeBuildInputs = [ makeWrapper ]; + postPatch = '' + # The upstream client hardcodes /sabnzbd/api as the API path. + # Change to just /api so SABNZBD_URL can optionally include the path prefix + # (e.g. http://host:9092/sabnzbd or just http://host:9092). + substituteInPlace client.py \ + --replace-fail '"{self.base_url}/sabnzbd/api"' '"{self.base_url}/api"' + ''; + installPhase = '' mkdir -p $out/lib/sabnzbd-mcp cp sabnzbd-mcp-server.py client.py $out/lib/sabnzbd-mcp/