Docker port bindings

docker ps command gives me:

PORTS
127.0.0.1:40000->8888/tcp 

Does it mean that port 40000 is busy and nobody can use given port?
I guess that is the case.

  • Impact of deleting mysql_embedded, mysqltest_embedded, mysqld-debug, mysql_client_test_embedded
  • What's the difference between a stack file and a Compose file?
  • How do I turn sendfile off in a docker instance
  • docker-compose for Detached mode
  • Location of docker images downloaded by Docker (1.9.1) on Mac OS X
  • Piping output to command and terminal
  • If so, why command lsof -i :40000 gives me an empty output?

  • Why is APCu segfaulting inside a Docker container?
  • Eureka cluster and docker-compose: Registering with host even when I set preferIpAdress: true
  • How to connect to containers on docker Overlay network from an external machine
  • Docker on embedded systems, why not?
  • Docker is stuck on “download complete” for pull
  • Running Disco in a Docker container
  • One Solution collect form web for “Docker port bindings”

    Yes, that does mean that port 40000 on 127.0.0.1 is being forwarded to a docker container. It does not necessarily mean that the container application is listening on port 8888 on all container interfaces (0.0.0.0) which is needed to complete that connection.

    Three reasons that I can think of where lsof -i :40000 would give no output:

    1. You didn’t run the lsof command as root
    2. Something has killed the docker-proxy process used to relay this traffic
    3. You ran the lsof command on a different machine than your docker host. Docker is a client/server app, and by setting $DOCKER_HOST you can connect to a remote machine to see the status of a remote host.
    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.