Questions tagged [docker-container]

Docker Containers are the core of the docker platform in which programs and applications can be packaged and run in simulated environments.

Docker containers are the core of the docker program in which programs and applications can run in simulated environments.

These containers serve as a way to simulate code that would otherwise cause irreversible changes to a systems hardware. The difference between this and a virtual machine is that the docker container does not run code on the same level as the virtual machine on top of the fact that it is a lot more portable.

Docker containers can be loaded with any type of environment, even your currently used machine, or serve as simple tool boxes for your file sytems.

For more info, see the official documentation of a docker container.

1187 questions
138
votes
4 answers

How to determine what containers use the docker volume?

Suppose I have a volume and I know its name or id. I want to determine the list of containers (their names or ids) that use the volume. What commands can I use to retrieve this information? I thought it can be stored in the output of docker volume…
gerichhome
  • 1,872
  • 2
  • 15
  • 21
137
votes
5 answers

'docker-compose' creating multiple instances for the same image

I need to start multiple containers for the same image. If I create my compose file as shown below, it works fine. version: '2' services: app01: image: app app02: image: app app03: image: app app04: image: app app05: …
KitKarson
  • 5,211
  • 10
  • 51
  • 73
123
votes
9 answers

Cannot remove images even though no container is running

I had multiple stopped containers and images on my machine. I want to clean up and remove all containers: docker ps -a returns nothing. I run docker rmi $(docker images -q) to remove the cached images but I get: Error response from daemon:…
Jim
  • 3,845
  • 3
  • 22
  • 47
61
votes
13 answers

Docker port forwarding not working

I have setup Docker container for access my machine docker container to another machine in local. Create a container below command: docker run -it -d --name containerName -h www.myhost.net -v /var/www/html -p 7000:8000 --net mynetwork --ip…
Rajkumar .E
  • 1,440
  • 3
  • 20
  • 34
51
votes
7 answers

docker on ubuntu 16.04 error when killing container

I can't kill or stop any docker container. I've allowed non-privileged users to run Docker commands. And docker run hello-world works fine. But I can't stop any other container. I got following: $ docker stop 59e3b815d1dc Error response from daemon:…
Peter
  • 1,223
  • 3
  • 11
  • 22
49
votes
5 answers

pause vs stop in docker

I am trying to understand what is the difference between the commands docker stop ContainerID and docker pause ContainerID. According to this page both of them are used to pause an existing Docker container.
ibodi
  • 1,543
  • 3
  • 21
  • 40
43
votes
2 answers

Docker image layer: What does `ADD file: in /` mean?

In Docker Hub images there are lists of commands that being run for each image layer. Here is a golang example. Some applications also provide their Dockerfile in GitHub. Here is a golang example. According to the Docker Hub image layer, ADD…
41
votes
4 answers

How to access files in host from a Docker Container?

I have a Docker Ubuntu Bionic container on A Ubuntu server host. From the container I can see the host drive is mounted as /etc/hosts which is not a directory. Tried unmounting and remounting on a different location but throws permission denied…
Just Khaithang
  • 1,217
  • 1
  • 14
  • 24
39
votes
1 answer

How are intermediate containers formed?

I would like to understand the execution steps involved in building Docker Images using Dockerfile. Couple of questions I have listed down below. Please help me in understanding the build process. Dockerfile content #from base image FROM…
Here_2_learn
  • 5,013
  • 15
  • 50
  • 68
39
votes
3 answers

Is it possible to start a stopped container from another container

There are two containers A and B. Once container A starts, one process will be executed, then the container will stop. Container B is just an web application (say expressjs). Is it possible to kickstart A from container B ?
tony.0919
  • 1,145
  • 5
  • 16
  • 27
33
votes
6 answers

AWS ECS Fargate Container Healthcheck command

I am trying to setup aws ecs fargate deployment configuration. I was able to run containers without container health check. But, I want to run container health checks too. I tried all possible scenarios to achieve this. But, no luck. i tried with…
Arjun
  • 533
  • 2
  • 9
  • 23
30
votes
8 answers

Update max_map_count for ElasticSearch docker container Mac host

I'm using this container to start elasticsearch in docker. In accordance with the manual I have to update max_map_count to start the container sudo sysctl -w vm.max_map_count=262144 but.. I can update it in my host (container) AFTER I start it…
Mando
  • 11,414
  • 17
  • 86
  • 167
28
votes
2 answers

Docker stats with CPU percentage more than 100

I have a question about docker stats command if anyone can help me. I am new in Docker area and I want to monitor the cpu usage of a docker container. The physical machine has 8 cores (CPU0...CPU7). I already create a container and limit its cpu…
SMA
  • 415
  • 1
  • 5
  • 10
26
votes
3 answers

How to use --since option with docker logs command

I want to look at last 1 hour of docker container log using docker logs --since option. Which value I should provide for --since parameter?
kgs
  • 1,654
  • 2
  • 18
  • 19
25
votes
2 answers

'make' command not found in docker container

I have a docker image which is running docker host with ubuntu 14.04. In one of the containers, I am trying to run zookeeper and install librdkafka libraries(pre-requisite library) for kafka to connect to 3rd party software. I need the 'make'…
Omkar
  • 2,274
  • 6
  • 21
  • 34
1
2
3
79 80