mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Don't warn if the shm or mquere is not mounted
Fix #33328 Signed-off-by: Jacob Wen <jian.w.wen@oracle.com>
This commit is contained in:
parent
01af41ed99
commit
cfa2591d3f
1 changed files with 4 additions and 1 deletions
|
@ -13,6 +13,7 @@ import (
|
||||||
containertypes "github.com/docker/docker/api/types/container"
|
containertypes "github.com/docker/docker/api/types/container"
|
||||||
mounttypes "github.com/docker/docker/api/types/mount"
|
mounttypes "github.com/docker/docker/api/types/mount"
|
||||||
"github.com/docker/docker/pkg/chrootarchive"
|
"github.com/docker/docker/pkg/chrootarchive"
|
||||||
|
"github.com/docker/docker/pkg/mount"
|
||||||
"github.com/docker/docker/pkg/stringid"
|
"github.com/docker/docker/pkg/stringid"
|
||||||
"github.com/docker/docker/pkg/symlink"
|
"github.com/docker/docker/pkg/symlink"
|
||||||
"github.com/docker/docker/pkg/system"
|
"github.com/docker/docker/pkg/system"
|
||||||
|
@ -220,7 +221,9 @@ func (container *Container) UnmountIpcMounts(unmount func(pth string) error) {
|
||||||
warnings = append(warnings, err.Error())
|
warnings = append(warnings, err.Error())
|
||||||
} else if shmPath != "" {
|
} else if shmPath != "" {
|
||||||
if err := unmount(shmPath); err != nil && !os.IsNotExist(err) {
|
if err := unmount(shmPath); err != nil && !os.IsNotExist(err) {
|
||||||
warnings = append(warnings, fmt.Sprintf("failed to umount %s: %v", shmPath, err))
|
if mounted, mErr := mount.Mounted(shmPath); mounted || mErr != nil {
|
||||||
|
warnings = append(warnings, fmt.Sprintf("failed to umount %s: %v", shmPath, err))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue