Questions tagged [docker-volume]

A docker data volume is a specially-designated directory within one or more containers that bypasses the Union File System.

A docker data volume is a specially-designated directory within one or more containers that bypasses the Union File System. Data volumes provide several useful features for persistent or shared data:

  • Volumes are initialized when a container is created. If the container’s base image contains data at the specified mount point, that existing data is copied into the new volume upon volume initialization.
  • Data volumes can be shared and reused among containers.
  • Changes to a data volume are made directly.
  • Changes to a data volume will not be included when you update an image.
  • Data volumes persist even if the container itself is deleted.

Reference: https://docs.docker.com/engine/userguide/dockervolumes/

1402 questions
-2
votes
1 answer

Is it possible to mount the host path or docker volume to the path in the image from dockerfile?

I want to mount my host path (or docker volume) to the path in the image from dockerfile. Dockerfile can copy the host data or directory to the data or directory in the image. But I want to bind or mount not copy! It is similar to "docker run -v"…
GiwoongLee
  • 43
  • 6
-2
votes
1 answer

Backup docker volume on a broken system. Volume recovery

I have a server that's been running in docker on coreos. For some reason containerd has stopped running and the docker daemon has stopped working correctly. My efforts to debug haven't gotten far. I'd like to just boot a new instance and migrate,…
-2
votes
1 answer

Kubernetes - How to use files from a directory in a pod?

I have a builder image / container which is supposed to run tests on a directory with tests sources. The container is run in a Kubernetes pod, in AWS EKS, through helm test. I.e. not docker, so I can't simply use -v volume mount. I am struggling to…
Ondra Žižka
  • 43,948
  • 41
  • 217
  • 277
-3
votes
1 answer

Docker-compose doesn't create volume when specified

I try to create a container that has a volume between my host and the container by specifying it on my docker-compose file but after the build and the container has started impossible for me to find the folder of the volume. Here is my…
4bdl
  • 9
  • 5
-3
votes
1 answer

Why Docker mounts only specific files in volume?

$ sw_vers ProductName: Mac OS X ProductVersion: 10.13.6 BuildVersion: 17G65 $ docker -v Docker version 18.06.0-ce, build 0ffa825 I have some docker-compose file that actually has this string of line: volumes: - .:/sql And In "."…
Michael A.
  • 1,071
  • 12
  • 21
-4
votes
1 answer

docker nginx Mount -v

docker run command error: (I was knocking on the document command, Docker version 18.03.0-ce), ask why? docker run -p 80:80 --name mynginx -v $PWD/www:/www -v $PWD/conf/nginx.conf:/etc/nginx/nginx.conf -v $PWD/logs:/wwwlogs -d nginx The error…
1 2 3
93
94