Cannot install bcrypt node.js module on Centos Server

后端 未结 4 1206
栀梦
栀梦 2020-12-03 15:49

I\'m trying to install bcrypt on CentOS server but I got the following error:

info postuninstall bcrypt@0.5.0
ERR! bcrypt@0.5.0 install: `make build`
ERR! `s         


        
4条回答
  •  心在旅途
    2020-12-03 16:27

    I got the same issue doing npm install bcrypt. The other option is to install it from source.

    git clone git://github.com/ncb000gt/node.bcrypt.js.git
    cd node.bcrypt.js
    node-gyp configure
    node-gyp build
    

    Rename the node.bcrypt.js folder to bcrypt, and move it into your node_modules of your project.

    You can install node-gyp by doing npm install -g node-gyp (-g installs it globally).

提交回复
热议问题