Skip to content

Build mounts guide + rw "discard" behavior #20549

Open
@milas

Description

Is this a docs issue?

  • My issue is about the documentation content or website

Type of issue

I can't find what I'm looking for

Description

In the Dockerfile reference @ https://docs.docker.com/reference/dockerfile/#run---mounttypebind, the docs for the rw param mention:

Written data will be discarded.

This is not covered anywhere in the guide for build mounts, which leads to the assumption that they behave like run mounts, which are bi-directional.

Location

https://docs.docker.com/build/guide/mounts/

Suggestion

Add a short explanation about the use-case for read-write mounts with clarification that they do NOT propagate back to the host and that all "written data will be discarded".

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions