Nuxt failing to find available port in Docker

I had an issue where the Nuxt application suddenly failed to start in the Docker container (DDEV).

The logs were showing the message:

[get-port] Unable to find an available port (tried 3000 on host "mysite.ddev.site").

This means that it tries to bind the port on the host mysite.ddev.site

What happened was that I had Nuxt devServer configured to use the host mysite.ddev.site. Debugging this took a while because this configuration worked for some time and stopped after I restarted everything. This is for specifying the host it tries to bind the port. In docker, it should be 0.0.0.0

Buy Me a Coffee at ko-fi.com

Add new comment