Docker deployment hangs on last step

I have a docker container for my client. At the end it serves on localhost:3000 like it should, but the deployment never ends. It waits and waits until eventually timing out and resulting in a failed build. I have had it deploy successfully in the past, but I added some environment variables on the render side of things recently and not the behavior I describe happens. The variables in an environment group and they are intentionally not listed in the Dockerfile to avoid duplicates. Obviously I can not share with you the variables, but I can say there are 18 in total.

Hi Benjamin,

Could you try listening on 0.0.0.0 instead of localhost.

I just ended up using my Dockerfile env variables and not connecting any through the render.com app. That works find.

I am also experiencing a similar issue where the CMD executes correctly, the server starts correctly, but then it hangs until the deploy fails.

The CMD is CMD ["node", "./dist/_backend/server.js"], which successfully starts and loads the server, but then the deploy fails after a long timeout.