From 017683f9e287e4e37d65eb88358cf07096b7c5fa Mon Sep 17 00:00:00 2001 From: hermes-agent Date: Thu, 13 Aug 2026 20:09:14 +0000 Subject: [PATCH] ovhcloud-mcp: add bin wrapper (upstream has no bin field) The upstream package.json has no 'bin' field, so buildNpmPackage produced no executable and the gateway could not spawn it ('No such file or directory'). Add a makeWrapper that runs node dist/index.js. --- packages/ovhcloud-mcp/package.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages/ovhcloud-mcp/package.nix b/packages/ovhcloud-mcp/package.nix index a4bce07..3f088ea 100644 --- a/packages/ovhcloud-mcp/package.nix +++ b/packages/ovhcloud-mcp/package.nix @@ -2,6 +2,8 @@ lib, buildNpmPackage, fetchFromGitHub, + makeWrapper, + nodejs, }: buildNpmPackage rec { @@ -17,12 +19,22 @@ buildNpmPackage rec { npmDepsHash = "sha256-myeqksb3mjJ1GJej/4D7iuyOOTsGJBdkka9zUpH+flY="; + nativeBuildInputs = [ makeWrapper ]; + postPatch = '' cp ${./package-lock.json} package-lock.json ''; # dist/ is NOT committed to the repo; buildNpmPackage runs "npm run build" # (tsc) by default, which emits dist/index.js. + # + # The upstream package.json has NO "bin" field, so buildNpmPackage produces + # no executable. Create a wrapper that runs node dist/index.js. + postInstall = '' + mkdir -p $out/bin + makeWrapper ${nodejs}/bin/node $out/bin/ovhcloud-mcp \ + --add-flags "$out/lib/node_modules/ovhcloud-mcp/dist/index.js" + ''; meta = with lib; { description = "OVHcloud MCP server - VPS, domains, DNS, billing, SSH, and API explorer"; -- 2.55.0