rlidwka / sinopia

Private npm repository server
5.51k stars 656 forks source link

Error: Cannot find module './build/Release/crypt3' #465

Open todojs opened 7 years ago

todojs commented 7 years ago

When we run this command on client:

npm adduser --registry http://myserver.com:4873

This error is displayed on server:

error --- unexpected error: Cannot find module './build/Release/crypt3' Error: Cannot find module './build/Release/crypt3' at Function.Module._resolveFilename (module.js:527:15) at Function.Module._load (module.js:476:23) at Module.require (module.js:568:17) at require (internal/module.js:11:18) at module.exports (/usr/lib/node_modules/sinopia/node_modules/crypt3/index.js:24:9) at Object.add_user_to_htpasswd (/usr/lib/node_modules/sinopia/node_modules/sinopia-htpasswd/utils.js:107:14) at /usr/lib/node_modules/sinopia/node_modules/sinopia-htpasswd/index.js:93:20 at callback (/usr/lib/node_modules/sinopia/node_modules/sinopia-htpasswd/utils.js:55:19) at /usr/lib/node_modules/sinopia/node_modules/sinopia-htpasswd/utils.js:59:21 at /usr/lib/node_modules/sinopia/node_modules/sinopia-htpasswd/utils.js:23:21 http <-- 500, user: undefined, req: 'PUT /-/user/org.couchdb.user:XXXX', error: internal server error

Node version: 8.7.0

todojs commented 7 years ago

We try to remove and install sinopia. This error is displayed continusly

gyp WARN EACCES user "root" does not have permission to access the dev dir "/usr/lib/node_modules/sinopia/node_modules/crypt3/.node-gyp/8.7.0" gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/lib/node_modules/sinopia/node_modules/crypt3/.node-gyp"

npm version: 5.5.1:

peterzhou84 commented 7 years ago

mkdir /usr/lib/node_modules/sinopia/node_modules/crypt3/.node-gyp mkdir /usr/lib/node_modules/sinopia/node_modules/crypt3/.node-gyp/8.7.0 and reinstall. After this, the installation should be ok. But, the crypt3 is still not working. I installed the crypt3 module separately and copied the installed crypt3 module the the target location(/usr/lib/node_modules/sinopia/node_modules/crypt3). It's working good now.

GodzillaHe commented 6 years ago

@rlidwka

GodzillaHe commented 6 years ago

I have the same problem.

GodzillaHe commented 6 years ago

it's working good on mac and windows. do i need install something for necessary on ubuntu ?