Docker volume
A Docker volume is Docker-managed storage mounted into containers whose data persists independently of their writable layers and lifecycles.
Road to Kubernetes
A Docker volume is storage mounted into a container that can persist data independently of the container filesystem and may be shared with the host or other containers.
- How it is used
- Makes ephemeral containers stateful by mounting storage for data that must survive container changes, including database data.
- How deep it goes
- Works through CLI mounts and Compose declarations, including ownership and deletion behavior; does not develop storage internals.
- Examples
- Uses a Python container’s shared sample file, Compose YAML mounts, and a Redis service with a `/data` mount.
- What you can do after
- Operate/configure it with `docker run -v` or Compose, verify mounted files, and avoid deleting needed managed-volume data.
Rust Servers, Services, and Apps
A Docker volume is Docker-managed persistent storage whose contents exist independently of a container's lifecycle.
- How it is used
- Persists PostgreSQL data across container runs in a Docker Compose deployment.
- How deep it goes
- Explains Docker-managed persistence, volume creation, and a Compose mount, but not backup or remote-driver procedures.
- Examples
- Mounts tutor-data at /var/lib/postgresql/data for a PostgreSQL container.
- What you can do after
- Configure a named volume and mount it as PostgreSQL’s data directory in Docker Compose.
Read how Rust Servers, Services, and Apps explains Docker volume →
100 SQL Server Mistakes and How to Avoid Them
A Docker volume is a Docker-managed persistent storage resource whose data resides outside a container's writable layer.
- How it is used
- Deploys SQL Server containers while keeping data after container removal.
- How deep it goes
- Defines volumes, explains host placement and driver choices, and demonstrates creation and container mapping commands.
- Examples
- Uses the sqldata volume and a SQL Server 2022 container mapped to /var/opt/mssql.
- What you can do after
- Operate/configure a SQL Server container with persistent storage using Docker volume and run commands.
Read how 100 SQL Server Mistakes and How to Avoid Them explains Docker volume →
Bootstrapping Microservices, Second Edition: With Docker, Kubernetes, GitHub Actions, and Terraform
A Docker volume is persistent storage managed separately from a container's writable filesystem and lifecycle.
- How it is used
- Shares host code and caches with development containers, enabling live reload and faster repeated npm installs.
- How deep it goes
- Explains Compose mappings and cleanup behavior, stopping short of broader volume administration.
- Examples
- Uses source-code and npm-cache mounts in a history microservice Compose service.
- What you can do after
- Configure Docker Compose mounts for live reload, cache retention, and clean volume-backed restarts.
Also covered in
What to know first
- containerA software container is an isolated execution environment that packages an application and its dependencies, typically sharing the host operating-system kernel.
- YAMLYAML is a human-readable data serialization standard for representing structured data, commonly using indentation to express mappings and sequences.
Related concepts
- containeruses · A software container is an isolated execution environment that packages an application and its dependencies, typically sharing the host operating-system kernel.
- configmapused by · A ConfigMap is a Kubernetes API resource that stores non-confidential configuration data as key-value pairs for use by workloads and other cluster components.
- Dockerproduced by · Docker is a platform and toolset for building, distributing, and running applications in containers.
- Docker Composeused by · Docker Compose is a tool for defining and running applications composed of multiple containers using declarative configuration.
- docker compose downconfigured by · docker compose down is a Docker Compose command that stops and removes service containers and networks, optionally removing managed volumes.
- Docker volume mountconfigured by · A Docker volume mount is a configuration that makes a host path or managed volume available at a specified path inside a container.
Questions about Docker volume
What is Docker volume?
A Docker volume is Docker-managed storage mounted into containers whose data persists independently of their writable layers and lifecycles.
Which Manning books explain Docker volume?
Road to Kubernetes, Rust Servers, Services, and Apps, 100 SQL Server Mistakes and How to Avoid Them and Bootstrapping Microservices, Second Edition: With Docker, Kubernetes, GitHub Actions, and Terraform.
What should I know before learning Docker volume?
Manning books that teach Docker volume usually introduce container and YAML first.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.



