3 months ago
The deploy does it correctly according to the logs, but when I try to access through the url provided by the railway container, it shows a 502 bad gateway error message and in the page an error saying that the application has failed to respond.
I do not understand what can be the problem.
5 Replies
3 months ago
Hey there! We've found the following might help you get unblocked faster:
If you find the answer from one of these, please let us know by solving the thread!
3 months ago
This thread has been marked as public for community involvement, as it does not contain any sensitive or personal information. Any further activity in this thread will be visible to everyone.
Status changed to Open brody • 3 months ago
3 months ago
Check your app is listening on the correct port
Railway expects your app to listen on:
PORT=8080
Make sure your server code uses:
app.listen(process.env.PORT || 8080);
3 months ago
my script in package.json it is
"start": "serve dist -s -n -L -p 8080"
because I use
"serve": "^14.2.4"
for up my app
2 months ago
Make sure you have set the port in public network to 8080
Attachments
phoenixauro
Make sure you have set the port in public network to 8080
2 months ago
Excellent, this worked. I hadn't realized that it was pointing to another port. Best regards and thank you.
Status changed to Solved brody • 3 months ago