错误:
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! react-amplify-project-three@0.1.0 build: `react-scripts --max_old_space_size=2048 build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the react-amplify-project-three@0.1.0 build 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! /root/.npm/_logs/2019-08-30T05_23_44_594Z-debug.log
在Bitbucket管道中运行此步骤:
- step:
name: Dev Docker Build
deployment: dev-docker-build
trigger: manual
size: 2x
script:
- npm install
- npm run build
使用的配置:
"scripts": {
"start": "react-scripts start",
"build": "react-scripts --max_old_space_size=2048 build",
"test": "react-scripts test",
"eject": "react-scripts eject"
对此有什么解决方案?
答案 0 :(得分:0)
对此我有答案。在您的npm命令中添加“ CI = false”这一行
- npm install
- CI=false npm run build