我将回购部署在heroku上,但是我一直收到应用程序错误。请注意,Heroku和Github已连接。因此该应用会自动部署
我已将引擎添加到package.json中,但这似乎无法解决问题
这是我从heroku中得到的错误
2019-05-08T10:24:52.962552+00:00 app[web.1]:
2019-05-08T10:24:52.962779+00:00 app[web.1]: npm ERR! A complete log of this run can be found in:
2019-05-08T10:24:52.962913+00:00 app[web.1]: npm ERR! /app/.npm/_logs/2019-05-08T10_24_52_957Z-debug.log
2019-05-08T10:24:53.021611+00:00 heroku[web.1]: Process exited with status 1
2019-05-08T10:25:08.906685+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=node-js-app.herokuapp.com request_id=f1847a93-53e4-43ad-8616-8867e95d31c3 fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
2019-05-08T10:25:10.823468+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=node-js-app.herokuapp.com request_id=898935d3-5dda-4407-929a-20f13956b6dd fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
2019-05-08T10:27:19.725919+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=node-js-app.herokuapp.com request_id=122efddd-b5f1-4cf6-b527-c429a787d0e0 fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
2019-05-08T10:27:21.466801+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=node-js-app.herokuapp.com request_id=e51dfc00-6b08-4601-ab61-8d490e6010c0 fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
2019-05-08T10:29:10.740930+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=node-js-app.herokuapp.com request_id=abdd29b6-7106-4a2f-8133-3440f33dfd92 fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
2019-05-08T10:29:12.643465+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=node-js-app.herokuapp.com request_id=264d0150-cbe3-4b5e-bccb-941b5ef84176 fwd="105.112.44.138" dyno= connect= service= status=503 bytes= protocol=https
这是我的package.json和server.js
"engines": {
"node": "10.13.0",
"npm": "6.x"
},
"scripts": {
"test": "nyc mocha --require @babel/register API/src/tests/index.test.js
--exit",
"build": "babel API/server.js --out-dir build",
"start": "babel-watch API/server.js",
}
...