bradtraversy / expense-tracker-mern

Full stack expense tracker
380 stars 193 forks source link

Deployment issue #5

Open brandoncroberts opened 4 years ago

brandoncroberts commented 4 years ago

This is my first time trying to deploy a MERN stack app. I followed most of the steps on this video as a reference on deploying it. https://www.youtube.com/watch?v=71wSzpLyW9k&t=211s

It does build successfully on Heroku, but when I open the app I am getting the following errors. Important to note that I get the exact same errors when I cloned Brad's project and deployed it. I do enter my MONGO_URI key as an environment variable.

Seems to be an issue with the path.

Link to my code just in case, https://github.com/8brandon/expense-tracker-react But like I said I have the same issue when cloning Brad's.

Thanks for you help

heroku[web.1]: State changed from up to crashed heroku[web.1]: Process exited with status 1

heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=nameless-river-88195.herokuapp.com request_id=3b914276-c9cc-4fdc-b7dc-952a12142624 fwd="95.90.246.172" dyno= connect= service= status=503 bytes= protocol=https

heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=nameless-river-88195.herokuapp.com request_id=ebaeff8a-a140-4d1f-9fe1-c2138d3fadb5 fwd="95.90.246.172" dyno= connect= service= status=503 bytes= protocol=https

potts99 commented 4 years ago

I think this maybe a cors issue, have a look at it, it's middleware that is needed

potts99 commented 4 years ago

Mine posts to heroku just fine if you want to have a look at the code https://github.com/jwandrews99/ReactJS-Expense-tracker