Questions tagged [docker]

Docker is an open source project that automates the deployment of applications inside software containers.

Docker is an open source project that automates the deployment of applications inside software containers. Docker extends a common container format called Linux Containers (LXC), with a high-level API providing a lightweight virtualization solution that runs processes in isolation. Docker utilizes LXC, cgroups, and the Linux kernel itself. Unlike traditional virtual machines, a Docker container does not include a separate operating system, instead it relies on the operating system’s functionality provided by the underlying infrastructure.

3896 questions
20
votes
1 answer

How to debug Docker cache invalidation?

Docker has a cache, which is great, but all I see in the "docker build" output is either: ---> Using cache or the output of the command (which implies it's not using the cache). After one step in my Dockerfile (a COPY), it clearly doesn't use the…
Timmay
  • 261
  • 1
  • 5
20
votes
2 answers

How do I deploy a docker container and associated data container, including contents?

I'll start by admitting I'm pretty new to Docker and I may be approaching this problem from the wrong set of assumptions... let me know if that's the case. I've seen lots of discussion of how Docker is useful for deployment but no examples of how…
Kryten
  • 313
  • 1
  • 2
  • 8
19
votes
1 answer

List containers from all nodes of docker swarm mode

We are running docker in swarm mode on a few nodes. Could not find a quick and easy way to list all containers (preferably with status) in the swarm from the manager nodes. One can see overlay networks and locally-running containers attached to…
saabeilin
  • 409
  • 1
  • 4
  • 11
19
votes
3 answers

Sharing unix socket via docker volume - permission denied

I try to share my php5-fpm socket via a volume with my nginx webserver. Fpm and nginx are running in different containers and I want to get them working via a shared volume where I place the socket file from fpm. 2014/04/13 10:53:35 [crit] 33#0: *1…
soupdiver
  • 797
  • 2
  • 8
  • 26
18
votes
2 answers

How to get the true client IP for a service running inside docker

My scenario: I'd like to have my docker-based services know what IP is calling them from the web (a requirement of my application.) I'm running on a cloud VPS, debian jessie, with docker 1.12.2. I use nc in verbose mode to open port 8080. docker run…
18
votes
5 answers

Can not access mysql docker

I am using docker-compose to create mysql container. I get host IP 172.21.0.2. But when I connect mysql. I get error: My docker-compose.yml: version: '2' services: ### Mysql container mysql: image: mysql:latest ports: -…
Quoc Dat
  • 183
  • 1
  • 1
  • 6
18
votes
3 answers

How to choose the external IP address of a Kubernetes load balancer in Google Kubernetes Engine

I'm deploying a web app using Google Kubernetes Engine and I want to make it accessible via a load balancer on an existing static IP address that I control as part of the same project in Google Cloud Platform, because the domain name I want to use…
18
votes
3 answers

Systemd fails to run in a docker container when using cgroupv2 (--cgroupns=private)

I will attach the minimized test case below. However, it is a simple Dockerfile that has these lines: VOLUME ["/sys/fs/cgroup"] CMD ["/lib/systemd/systemd"] It is Debian:buster-slim based image, and runs systemd inside the container. Effectively, I…
Stephen
  • 293
  • 1
  • 2
  • 4
17
votes
3 answers

How to move docker images to other drive in windows

I try to run the following script but dockerd is not recognized in my workstation. My OS is windows 10. Just installed the latest version of docker that is 18.09.2 It is my first time with docker.
Miguel
  • 511
  • 4
  • 7
  • 16
17
votes
2 answers

Docker breaks libvirt bridge network

This issue is driving me crazy. I run a fresh install of Ubuntu 18.04, with: ufw to manage the firewall a br0 bridge lxd and libvirt (KVM) I tried stock docker.io package and packages form docker's own deb repository. I want o be able to deploy…
Laurent
  • 286
  • 2
  • 11
17
votes
4 answers

Is it a good practice to put update/upgrade statements inside the Dockerfile?

new to Docker here and I am trying to make it right. I want to create a docker container to 'deep freeze' an application created with bash scripts and a lot of dependencies, so that I don't have to maintain it as much anymore. I think docker is…
MortyAndFam
  • 181
  • 1
  • 1
  • 3
17
votes
2 answers

Docker - Exposed ports accessible from outside - iptables rules ignored

I have a docker container running like: docker run --name some_container_1 -p 8080:80 -d some_image Which works fine. The container exposes it's port 80 to 8080 and is accessible from localhost. For some reason however it's ignoring the…
binaryanomaly
  • 406
  • 1
  • 4
  • 14
17
votes
1 answer

Update Docker container without downtime

Let's say I have a Docker container with a web server (like Apache 2). Now I want to update the OS under it. This SF answer says the best way is to rebuild the base image and my Apache image. But deploying the image means downtime because I have to…
das_j
  • 223
  • 2
  • 7
17
votes
7 answers

Docker & Shorewall

I'm using Shorewall on my server as simple standalone firewall and would like to use Docker as well. By using a Docker container and its port redirection docker sets up its own iptables rules/chains which will be killed if shorewall is restarted. So…
jaltek
  • 283
  • 3
  • 9
16
votes
2 answers

How and where to configure pm.max_children for php-fpm with Docker?

In a Web application with Nginx and PHP-FPM, I've noticed moments of slowness and analyzing the logs, I found this message, which appears from time to time: [19-Nov-2017 19:24:09] WARNING: [pool www] server reached pm.max_children setting (5),…
lfalmeida
  • 163
  • 1
  • 1
  • 4