Skylar-Tech / node-red-contrib-matrix-chat

Matrix chat server support for Node-RED
GNU General Public License v3.0
31 stars 10 forks source link

Failed installation in node-red docker container #107

Closed jotempel closed 6 months ago

jotempel commented 6 months ago

Hi, is it even possible to install node-red-contrib-matrix-chat in the docker (https://hub.docker.com/r/nodered/node-red) version of node-red? I get the following log output:

2023-12-18T22:04:26.520Z Installieren : node-red-contrib-matrix-chat 0.7.1

2023-12-18T22:04:26.315Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-contrib-matrix-chat@0.7.1
2023-12-18T22:04:26.618Z [err] npm
2023-12-18T22:04:26.618Z [err]  WARN 
2023-12-18T22:04:26.618Z [err] config production Use `--omit=dev` instead.
2023-12-18T22:05:03.949Z [err] npm
2023-12-18T22:05:03.949Z [err]  ERR! code EBADENGINE
2023-12-18T22:05:03.950Z [err] npm ERR!
2023-12-18T22:05:03.950Z [err]  engine Unsupported engine
2023-12-18T22:05:03.950Z [err] npm ERR! engine Not compatible with your version of node/npm: matrix-js-sdk@28.2.0
2023-12-18T22:05:03.950Z [err] npm ERR! notsup Not compatible with your version of node/npm: matrix-js-sdk@28.2.0
2023-12-18T22:05:03.950Z [err] npm ERR! 
2023-12-18T22:05:03.950Z [err] notsup Required: {"node":">=18.0.0"}
2023-12-18T22:05:03.950Z [err] npm ERR! notsup Actual:   {"npm":"8.19.4","node":"v16.20.2"}
2023-12-18T22:05:03.951Z [err] 
2023-12-18T22:05:03.952Z [err] npm ERR! A complete log of this run can be found in:
2023-12-18T22:05:03.952Z [err] npm ERR!     /data/.npm/_logs/2023-12-18T22_04_26_592Z-debug-0.log
2023-12-18T22:05:03.974Z rc=1
skylord123 commented 6 months ago

Yes you can install this in the Docker version. That is how I run it myself.

2023-12-18T22:05:03.950Z [err]  engine Unsupported engine
2023-12-18T22:05:03.950Z [err] npm ERR! engine Not compatible with your version of node/npm: matrix-js-sdk@28.2.0
2023-12-18T22:05:03.950Z [err] npm ERR! notsup Not compatible with your version of node/npm: matrix-js-sdk@28.2.0
2023-12-18T22:05:03.950Z [err] npm ERR! 
2023-12-18T22:05:03.950Z [err] notsup Required: {"node":">=18.0.0"}
2023-12-18T22:05:03.950Z [err] npm ERR! notsup Actual:   {"npm":"8.19.4","node":"v16.20.2"}

Unsupported engine means you are running a version of node that isn't supported by the package you are installing.

notsup Required: {"node":">=18.0.0"} is the part that tells you what version of node you need (in this case version 18)

npm ERR! notsup Actual: {"npm":"8.19.4","node":"v16.20.2"} This is telling you that you are using node version 16.

So you need to upgrade the Node-RED container to node version 18 to use this package. On my home server I am using docker package/version nodered/node-red:latest-18 to accomplish this.

jotempel commented 6 months ago

Thanks, my problem is solved, with the latest-18 image I can install the extra node without any problems.