Trying to use GridDB Node.js client on WSL (Ubuntu 22.04) with Node.js v18, but the installation fails.
Steps I followed:
sudo apt install -y nodejs build-essential
node -v # 18.20.8
npm -v # 10.8.2
mkdir ~/gridDB-node
cd ~/gridDB-node
npm init -y
npm install griddb-node-api
Error:
npm error gyp: binding.gyp not found (cwd: /home/eagle04/gridDB-node/node_modules/griddb-node-api)
npm error gyp ERR! configure error
npm error gyp ERR! stack Error: gyp failed with exit code: 1
I also tried Node.js v20, but the error persisted and checked the GridDB repo (griddb_nosql), but the expected Node.js client folder (client/nodejs) does not exist in the repo.
Environment:
WSL Ubuntu 22.04, Node.js v18.20.8, NPM v10.8.2, GridDB server v5.8
I have checked all related questions and found this similar.
Issue installing griddb-node-api on Ubuntu with GridDB v5.5 and Node.js v20.11
However, In this case they used GridDB v5.5, I used 5.8. I’ve tried Node.js multiple version- v20,v18. The environment likely Ubuntu but in my case OS was WSL. I also cloned the GitHub repo and the folder structure (client/nodejs, client/javascript, etc) seems missing or changed.
What I want to know: A working way to install GridDB Node.js client on WSL. Guidance if I need a specific Node.js version, or if additional libraries/environment variables are required.