I just set up a new web service and can’t get it to successfully deploy. It’s stuck in the “In progress” state forever.
The log ends with:
Jun 8 09:48:13 PM ==> Starting service with 'npm start'
Jun 8 09:48:13 PM
Jun 8 09:48:13 PM > socket.dev@1.0.0 start
Jun 8 09:48:13 PM > NODE_ENV=production node .
Jun 8 09:48:13 PM
Jun 8 09:48:14 PM Listening on port 10000
So the Node server is running, but the “In progress” loading indicator keeps spinning forever and no HTTP requests are routed to the service.
Also – is there a better way to contact support when dealing with issues like this?
False alarm. Found the issue. If you bind to localhost, then render can’t find the service.
httpServer.listen(port, '127.0.0.1', err => {
if (err) throw err
console.log(`Listening on port ${port}`)
})
Needs to be this instead:
httpServer.listen(port, '0.0.0.0', err => {
if (err) throw err
console.log(`Listening on port ${port}`)
})
Would have been nice to have Render periodically log that it was waiting for a service to start listening on port 10000 on all interfaces, to serve as a pointer in the right direction.
That’s true, it’s still on the list, however we’ve been working hard on other parts of the platform and this particular catch hasn’t been implemented yet.
0.0.0.0 is the host your app should use and that should also be more clear in the docs, which I’ll look to add.