I would like to write some function node using aws-sdk in my Node-RED running as a docker container (official image nodered/node-red:2.2.2-14).
I tried both
npm install aws-sdkfrom the command line (from directory
/dataas user node-red) or
- adding module
AWSin the setup block of my function node
In both case I end-up with the following error log:
npm WARN deprecated firstname.lastname@example.org: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. npm WARN deprecated email@example.com: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm ERR! code ENOENT npm ERR! syscall rename npm ERR! path /data/node_modules/aws-sdk npm ERR! dest /data/node_modules/.aws-sdk.DELETE npm ERR! errno -2 npm ERR! enoent ENOENT: no such file or directory, rename '/data/node_modules/aws-sdk' -> '/data/node_modules/.aws-sdk.DELETE' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent npm ERR! A complete log of this run can be found in: npm ERR! /data/.npm/_logs/2022-04-06T21_42_30_350Z-debug.log
What am I doing wrong ?