Search code examples
node.jsnpmheroku

I am facing problem with a deployment of my app on Heroku


2021-12-24T04:43:27.112706+00:00 app[web.1]: npm ERR! code ELIFECYCLE
2021-12-24T04:43:27.112946+00:00 app[web.1]: npm ERR! errno 1
2021-12-24T04:43:27.118189+00:00 app[web.1]: npm ERR! [email protected] start: `node server.js`
2021-12-24T04:43:27.118270+00:00 app[web.1]: npm ERR! Exit status 1
2021-12-24T04:43:27.118387+00:00 app[web.1]: npm ERR!
2021-12-24T04:43:27.118471+00:00 app[web.1]: npm ERR! Failed at the [email protected] start script.
2021-12-24T04:43:27.118553+00:00 app[web.1]: npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
2021-12-24T04:43:27.136514+00:00 app[web.1]:
2021-12-24T04:43:27.136644+00:00 app[web.1]: npm ERR! A complete log of this run can be found in:
2021-12-24T04:43:27.136713+00:00 app[web.1]: npm ERR!     /app/.npm/_logs/2021-12-24T04_43_27_119Z-debug.log
2021-12-24T04:43:27.267717+00:00 heroku[web.1]: Process exited with status 1
2021-12-24T04:43:27.332502+00:00 heroku[web.1]: State changed from starting to crashed
2021-12-24T04:43:31.584721+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=drug-guard-web-app.herokuapp.com request_id=4a78fdb8-0a38-42ae-bf95-39e6c677bff3 fwd="37.111.206.26" dyno= connect= service= status=503 bytes= protocol=https
2021-12-24T04:43:32.204382+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=drug-guard-web-app.herokuapp.com request_id=844ade39-826a-4094-9e72-d1265fb2c47e fwd="37.111.206.26" dyno= connect= service= status=503 bytes= p

Solution

  • Not so sure but please try this.

    1. Delete package-lock.json file and node_modules folder
    2. Then do npm cache clean npm cache clean --force
    3. Run npm install
    4. And try pushing to heroku again