Docker Community Forums

Share and learn in the Docker community.

Cannot browse .net core app in container


(Docdockerman) #1

Hi
I’m pretty new to docker, so maybe a basic question. Could not google it.

I have built a simple app in .net core and I have let vs2k17 create a docker file. (Linux)
This runs fine in local dev env.
I have followed instructions on gitlab how to upload the dockerfile to their CR.

docker build -t registry.gitlab. com/[user]/[proj] .
docker push registry.gitlab. com/[user]/[proj]

This seems successful.

Now I want to run my docker file in local dev env:
docker run registry.gitlab. com/[user]/[proj]

This gives me: “Now listening on xxxxx” and “Application started”.

I use this to find ip address:
docker inspect -f ‘{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}’ [id]

Then I browse that url but the application cannot be reached.

I checked the logs: docker logs [id]
but I see only warnings, no errors

How to I troubleshoot this? (Im on win10)