mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
deprecate bind path auto-create
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
This commit is contained in:
parent
d2e7ba42b1
commit
249f45bcfe
2 changed files with 12 additions and 0 deletions
|
@ -53,6 +53,7 @@ func (m *mountPoint) Setup() (string, error) {
|
||||||
if !os.IsNotExist(err) {
|
if !os.IsNotExist(err) {
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
logrus.Warnf("Auto-creating non-existant volume host path %s, this is deprecated and will be removed soon", m.Source)
|
||||||
if err := system.MkdirAll(m.Source, 0755); err != nil {
|
if err := system.MkdirAll(m.Source, 0755); err != nil {
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
|
|
@ -89,3 +89,14 @@ The following double-dash options are deprecated and have no replacement:
|
||||||
docker ps --since-id
|
docker ps --since-id
|
||||||
docker ps --before-id
|
docker ps --before-id
|
||||||
docker search --trusted
|
docker search --trusted
|
||||||
|
|
||||||
|
### Auto-creating missing host paths for bind mounts
|
||||||
|
**Deprected in Release: v1.9**
|
||||||
|
|
||||||
|
**Target for Removal in Release: 1.11**
|
||||||
|
|
||||||
|
When creating a container with a bind-mounted volume-- `docker run -v /host/path:/container/path` --
|
||||||
|
docker was automatically creating the `/host/path` if it didn't already exist.
|
||||||
|
|
||||||
|
This auto-creation of the host path is deprecated and docker will error out if
|
||||||
|
the path does not exist.
|
||||||
|
|
Loading…
Reference in a new issue