npm install在`eb create`节点6.2.2上失败

时间:2016-09-27 04:04:00

标签: node.js npm amazon-elastic-beanstalk

其他人有这个问题吗?

1620 verbose unsafe-perm in lifecycle false
1621 info bufferutil@1.2.1 Failed to exec install script
1622 verbose stack Error: bufferutil@1.2.1 install: `node-gyp rebuild`
1622 verbose stack Exit status 1
1622 verbose stack at EventEmitter.<anonymous> (/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/lib/node_modules/npm/lib/utils/lifecycle.js:217:16)
1622 verbose stack at emitTwo (events.js:87:13)
1622 verbose stack at EventEmitter.emit (events.js:172:7)
1622 verbose stack at ChildProcess.<anonymous> (/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/lib/node_modules/npm/lib/utils/spawn.js:24:14)
1622 verbose stack at emitTwo (events.js:87:13)
1622 verbose stack at ChildProcess.emit (events.js:172:7)
1622 verbose stack at maybeClose (internal/child_process.js:827:16)
1622 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
1623 verbose pkgid bufferutil@1.2.1
1624 verbose cwd /tmp/deployment/application
1625 error Linux 4.4.14-24.50.amzn1.x86_64
1626 error argv "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/node" "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/npm" "--production" "install"
1627 error node v4.4.6
1628 error npm v2.15.5
1629 error code ELIFECYCLE
1630 error bufferutil@1.2.1 install: `node-gyp rebuild`
1630 error Exit status 1
1631 error Failed at the bufferutil@1.2.1 install script 'node-gyp rebuild'.
1631 error This is most likely a problem with the bufferutil package,
1631 error not with npm itself.
1631 error Tell the author that this fails on your system:
1631 error node-gyp rebuild
1631 error You can get information on how to open an issue for this project with:
1631 error npm bugs bufferutil
1631 error Or if that isn't available, you can get their info via:
1631 error
1631 error npm owner ls bufferutil
1631 error There is likely additional logging output above.
1632 verbose exit 1, true 

/var/log/eb-activity.log
Running npm with --production flag
Failed to run npm install. Snapshot logs for more details.
Traceback (most recent call last):
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 695, in <module>
main()
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 677, in main
node_version_manager.run_npm_install(options.app_path)
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 136, in run_npm_install
self.npm_install(bin_path, self.config_manager.get_container_config('app_staging_dir'))
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 180, in npm_install
raise e
subprocess.CalledProcessError: Command '' returned non-zero exit status 1 (ElasticBeanstalk::ExternalInvocationError)
caused by: + /opt/elasticbeanstalk/containerfiles/ebnode.py --action npm-install

bufferutil@1.2.1 install /tmp/deployment/application/node_modules/bufferutil
node-gyp rebuild

gyp ERR! clean error
gyp ERR! stack Error: EACCES: permission denied, rmdir 'build'
gyp ERR! stack at Error (native)
gyp ERR! System Linux 4.4.14-24.50.amzn1.x86_64
gyp ERR! command "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/node" "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/deployment/application/node_modules/bufferutil
gyp ERR! node -v v4.4.6
gyp ERR! node-gyp -v v3.3.1
gyp ERR! not ok

npm ERR! Linux 4.4.14-24.50.amzn1.x86_64
npm ERR! argv "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/node" "/opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/npm" "--production" "install"
npm ERR! node v4.4.6
npm ERR! npm v2.15.5
npm ERR! code ELIFECYCLE
npm ERR! bufferutil@1.2.1 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bufferutil@1.2.1 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the bufferutil package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs bufferutil
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!
npm ERR! npm owner ls bufferutil
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /tmp/deployment/application/npm-debug.log
Running npm install: /opt/elasticbeanstalk/node-install/node-v4.4.6-linux-x64/bin/npm
Setting npm config jobs to 1
npm config jobs set to 1
Running npm with --production flag
Failed to run npm install. Snapshot logs for more details.
Traceback (most recent call last):
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 695, in <module>
main()
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 677, in main
node_version_manager.run_npm_install(options.app_path)
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 136, in run_npm_install
self.npm_install(bin_path, self.config_manager.get_container_config('app_staging_dir'))
File "/opt/elasticbeanstalk/containerfiles/ebnode.py", line 180, in npm_install
raise e
subprocess.CalledProcessError: Command '' returned non-zero exit status 1 (Executor::NonZeroExitStatus)

1 个答案:

答案 0 :(得分:1)

基本上我只是将node_modules /添加到.ebignore并且它有效。

Node.js deployment fails on Amazon Elastic Beanstalk due to directory permissions

相关问题