When I run my nodeJs API on localhost is works perfect but when in uploaded it on server (Heroku) then it gives server 503 error.
Asked
Active
Viewed 486 times
0
-
2have you looked at the logs for your app on heroku? including something from those may help people understand the problem. – Ryan Quinn Mar 15 '20 at 19:47
-
Please review https://stackoverflow.com/help/how-to-ask to help you improve this question, and also your chances of getting the answer you need. – elight Mar 16 '20 at 03:49
1 Answers
0
Without knowing more about the project, my first guess is something that I ran into just yesterday, where Environment Variables hadn't been declared within Heroku > App > Settings > Config Vars, but were properly in place in the dev environment in the .env file (which should never, ever, ever be pushed to any repository, just so you're aware).
If you could run heroku logs --tail
in your CLI and paste in the log for that app, it could help clarify exactly what's happening.

R Greenstreet
- 719
- 6
- 21