-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
failed to bind to $PORT in Heroku running environment #2176
Comments
@hacksparrow, do you think you can help here? Thanks. |
Taking a look. |
Create a file named
|
FWIW, it would be great to have a Heroku Deployment guide in our docs, where we can describe these specific steps. |
@hacksparrow I added the Procfile and then I got another error. Did you see this error?2019-01-17T06:57:03.170917+00:00 heroku[web.1]: Starting process with command
|
That means the |
+1. |
@hacksparrow The default behaviour is to run "npm start" which would run "prestart" before "start". As you can see from the log. The issue is the $Port was not bind correctly. I don't think a Procfile would fix the port issue. Can you update the official Hello world example so that it can be just connected by Heroku and running on Heroku? @dhmlau I can do that when the issue is fixed. 2019-01-17T23:58:17.092418+00:00 heroku[web.1]: Starting process with command |
Hi @tonychangcheng , you should try to change config in index.js |
@quaywin Thanks for your comments. It worked for me as well. |
Just for posterity sake, you should only build your application at the build/deploy stage. You can have You will still get the See |
@adesege, thanks for the info. Would you like to contribute to our docs on deploying to Heroku? I'm thinking of putting it under "How To": https://loopback.io/doc/en/lb4/How-tos.html. Thanks. |
Hi @tonychangcheng / @quaywin i tried as per your previous comment to set host in index.js but still i'm getting localhost in heroku deployment. Could you please help me on this. 2020-09-20T16:49:29.516050+00:00 app[web.1]: [1] In Recommender Package 0.0.0.0 60148 |
Description / Steps to reproduce / Feature proposal
Current Behavior
Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
Expected Behavior
The port should be bind correctly.
The repo is here https://github.com/jiangren-mel-fullstack-1812/cheng-lb4-order-api
The text was updated successfully, but these errors were encountered: