Docker Detached Mode

What is detached mode in the docker world? I read this article
Link, but it does not explain exactly what detached mode mean.

  • Cannot connect to SQL Server from a Docker container
  • Docker image size not matching the container size after a commit
  • docker-compose start “ERROR: No containers to start”
  • Tilde Expansion Doesn't Work in Docker COPY Command
  • Issue while indexing data in solr in docker cluster setup
  • Mirroring private docker registry
  • Neo4j in Docker - Max Heap Size Causes Hard crash 137
  • jq returns null from curl
  • insufficient_scope error with docker registry v2 and curl
  • Unable to push windows docker image to Artifactory
  • Multiple commands during docker run
  • How to set image stored path in docker registry?
  • One Solution collect form web for “Docker Detached Mode”

    You can start a docker container in detached mode with a -d option. So the container starts up and run in background. That means, you start up the container and could use the console after startup for other commands.

    The opposite of detached mode is foreground mode. That is the default mode, when -d option is not used. In this mode, the console you are using to execute docker run will be attached to standard input, output and error. That means your console is attached to the container’s process.

    In detached mode, you can follow the standard output of your docker container with docker logs -f <container_ID>.

    Just try both options. I always use the detached mode to run my containers. I hope I could explain it a little bit clearer.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.