mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Give context for the error that occures when you try to bind mount a volume with a relative path
Docker-DCO-1.1-Signed-off-by: Timothy <timothyhobbs@seznam.cz> (github: timthelion)
This commit is contained in:
parent
ccbaf4bc6e
commit
7aed2130f9
1 changed files with 1 additions and 1 deletions
|
@ -232,7 +232,7 @@ func initializeVolume(container *Container, volPath string, binds map[string]Bin
|
||||||
destination = bindMap.SrcPath
|
destination = bindMap.SrcPath
|
||||||
|
|
||||||
if !filepath.IsAbs(destination) {
|
if !filepath.IsAbs(destination) {
|
||||||
return fmt.Errorf("%s must be an absolute path", destination)
|
return fmt.Errorf("cannot bind mount volume: %s volume paths must be absolute.", destination)
|
||||||
}
|
}
|
||||||
|
|
||||||
if strings.ToLower(bindMap.Mode) == "rw" {
|
if strings.ToLower(bindMap.Mode) == "rw" {
|
||||||
|
|
Loading…
Add table
Reference in a new issue