R
Railwayβ€’9mo ago
Darryl

Docker builds but fails to start application

Hey πŸ‘‹πŸΎ when I deploy my Dockerfile on Railway it builds ok but it fails on startup. However building & starting the Dockerfile locally it works just fine. Would anyone know why this could be? For what it's worth I'm using a Bun's docker image..
16 Replies
Percy
Percyβ€’9mo ago
Project ID: 45499fe6-6ec5-43b9-aca6-872b5076de23
Brody
Brodyβ€’9mo ago
it fails on startup
please provide error messages
Darryl
Darrylβ€’9mo ago
It doesn't provide an error message even wrapping it within a try/catch block
No description
Darryl
Darrylβ€’9mo ago
The console log isn't true btw Hitting the endpoint I get a 503 error
Brody
Brodyβ€’9mo ago
you need to listen on the PORT environment variable
Darryl
Darrylβ€’9mo ago
Let me try that!
Darryl
Darrylβ€’9mo ago
Hey this is still throwing an error. I've even set my own port manually within Railway itself
No description
No description
Brody
Brodyβ€’9mo ago
what did you set PORT to in railway?
Darryl
Darrylβ€’9mo ago
8000
Brody
Brodyβ€’9mo ago
still 503? make sure the app is also listing on host 0.0.0.0
Darryl
Darrylβ€’9mo ago
I lied. My client wasn't using the secure protocol when connecting to the websocket. Thank you @Brody πŸ™πŸΎ
Brody
Brodyβ€’9mo ago
sounds goods!
Darryl
Darrylβ€’9mo ago
But a quick question. I'm not seeing any of the logging within the deploy logs
Brody
Brodyβ€’9mo ago
are you logging unbuffered to stdout / stderr?
Darryl
Darrylβ€’9mo ago
I believe so if console.log is unbuffered?
Brody
Brodyβ€’9mo ago
with nodejs, yes with bun, no clue
Want results from more Discord servers?
Add your server