Search code examples
herokudeploymentheroku-cli

Heroku error during deployment of mern application


I just tried to deploy my first heroku application, but unfortunately I am getting an error.

The command heroku logs --tail throws the following error:

2020-02-14T16:35:34.990792+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/"host=agile-wildwood-52268.herokuapp.com request_id=5edfe87f-b4c7-42ee-a856-03ab806613ec fwd="88.68.64.245" dyno= connect= service= status=503 bytes= protocol=https

2020-02-14T16:35:37.110579+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=agile-wildwood-52268.herokuapp.com request_id=4e0aeeee-f828-4f85-a18c-25d54bfe3221 fwd="88.68.64.245" dyno= connect= service= status=503 bytes= protocol=https

I don't know where this error might be caused, any help is appreciated. Thank you


Solution

  • So I figured out the problem. I didn't have my environment variables set on the heroku dashboard. If you get a similar problem follow those steps:

    1. Go to https://dashboard.heroku.com/apps
    2. Click on your application
    3. Go to settings and click on "reveal config vars"
    4. Enter all your environment variables

    Hope it helps