Node.js AWS Elastic Beanstalk |错误:无法运行npm安装。有关更多详细信息,请参阅快照日志
我正在尝试部署Reactjs/Firebase应用程序(使用material UI模板制作),但当我通过上载代码创建新环境时,它显示以下错误: 日志文件中显示的错误:Node.js AWS Elastic Beanstalk |错误:无法运行npm安装。有关更多详细信息,请参阅快照日志,node.js,amazon-web-services,npm,amazon-elastic-beanstalk,Node.js,Amazon Web Services,Npm,Amazon Elastic Beanstalk,我正在尝试部署Reactjs/Firebase应用程序(使用material UI模板制作),但当我通过上载代码创建新环境时,它显示以下错误: 日志文件中显示的错误: npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! grpc@1.23.3 install: `node-pre-gyp install --fallback-to-build --library=static_library` npm ERR! Exit statu
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.23.3 install: `node-pre-gyp install --fallback-to-build --library=static_library`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.23.3 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /tmp/.npm/_logs/2020-02-03T17_23_00_028Z-debug.log
Running npm install: /opt/elasticbeanstalk/node-install/node-v10.15.1-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.
UTC 2020/02/03 17:23:00 cannot find application npm debug log at /tmp/deployment/application/npm-debug.log
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 '['/opt/elasticbeanstalk/node-install/node-v10.15.1-linux-x64/bin/npm', '--production', 'install']' returned non-zero exit status 1 (Executor::NonZeroExitStatus)
npm错误!代码失效循环
npm错误!错误1
npm错误!grpc@1.23.3install:`node pre-gyp install--fallback to build--library=static\u library`
npm错误!退出状态1
npm错误!
npm错误!失败grpc@1.23.3安装脚本。
npm错误!这可能不是npm的问题。上面可能还有其他日志输出。
npm错误!此运行的完整日志可在以下位置找到:
npm错误/tmp/.npm/_logs/2020-02-03T17_23_00_028Z-debug.log
正在运行npm安装:/opt/elasticbeanstalk/node安装/node-v10.15.1-linux-x64/bin/npm
将npm配置作业设置为1
npm配置作业设置为1
使用--production标志运行npm
无法运行npm安装。有关更多详细信息,请参阅快照日志。
UTC 2020/02/03 17:23:00在/tmp/deployment/application/npm-debug.log中找不到应用程序npm调试日志
回溯(最近一次呼叫最后一次):
文件“/opt/elasticbeanstalk/containerfiles/ebnode.py”,第695行,中
main()
文件“/opt/elasticbeanstalk/containerfiles/ebnode.py”,第677行,主目录
节点\u版本\u管理器。运行\u npm\u安装(选项。应用程序\u路径)
文件“/opt/elasticbeanstalk/containerfiles/ebnode.py”,第136行,在run\u npm\u install中
self.npm\u安装(bin\u路径,self.config\u管理器.get\u容器\u配置('app\u staging\u dir'))
文件“/opt/elasticbeanstalk/containerfiles/ebnode.py”,第180行,在npm_安装中
提高e
subprocess.CalledProcessError:命令“[”/opt/elasticbeanstalk/node install/node-v10.15.1-linux-x64/bin/npm',“--production”,“install']”返回非零退出状态1(执行器::NonZeroExitStatus)
我多次尝试重建环境,但都显示了相同的错误
错误的原因可能是什么?我可以尝试什么来修复它
我正在使用节点版本10.15.1
找不到应用程序npm调试日志
参考这个