mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #4264 from ndarilek/2973-skip-volumes-from
Don't call applyVolumesFrom on containers with volumes already configure...
This commit is contained in:
commit
1ad14effb5
1 changed files with 3 additions and 3 deletions
|
@ -23,11 +23,11 @@ func prepareVolumesForContainer(container *Container) error {
|
||||||
if container.Volumes == nil || len(container.Volumes) == 0 {
|
if container.Volumes == nil || len(container.Volumes) == 0 {
|
||||||
container.Volumes = make(map[string]string)
|
container.Volumes = make(map[string]string)
|
||||||
container.VolumesRW = make(map[string]bool)
|
container.VolumesRW = make(map[string]bool)
|
||||||
|
if err := applyVolumesFrom(container); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if err := applyVolumesFrom(container); err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
if err := createVolumes(container); err != nil {
|
if err := createVolumes(container); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue