鬼CMS – sudo npm安装 – 生产 – 错误

我正在尝试在当地的stream浪者箱子上安装鬼怪cms。

在我input“sudo npm install –production”后,我得到这个错误:

npm ERR! Linux 3.16.0-4-amd64 npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "--production" npm ERR! node v4.2.3 npm ERR! npm v3.5.1 `npm ERR! path /var/www/html/ghost/node_modules/node-pre- `gyp/node_modules/rc/node_modules/strip-json-comments/cli.js npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall chmod npm ERR! enoent ENOENT: no such file or directory, chmod '/var/www/html/ghost/node_modules/node-pre-gyp/node_modules/rc/node_modules/strip-json-comments/cli.js' npm ERR! enoent ENOENT: no such file or directory, chmod '/var/www/html/ghost/node_modules/node-pre-gyp/node_modules/rc/node_modules/strip-json-comments/cli.js' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent 

谁能帮我这个?

我遇到了同样的问题,我通过在/usr/bin运行下面的代码来修复它

 $ sudo apt install nodejs-legacy 

一旦安装,回头到你的ghost安装目录,并重新运行sudo npm install --production