HTTP hangs listening. On termination it claims Cannot GET

The following are log entries on running the app:

Starting HTTP server
Server listening on Port 8080

It hangs there and when I check the port by

curl http://localhost:8080/

I get the following response:

Error
Cannot GET /

Then when I stop running the application from inside the container I get the following error messages:
npm ERR! path /app
npm ERR! command failed
npm ERR! signal SIGTERM
npm ERR! command sh -c node build/main.js

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2022-12-23T11_39_53_072Z-debug-0.log

What is going on? Could it be the firewall not allowing access?
I have searched the documentation and the forum but I can’t find anything.
I am also a novice with the docker desktop.