|
@@ -214,6 +214,12 @@ func populateCommand(c *Container, env []string) error {
|
|
ipc.ContainerID = ic.ID
|
|
ipc.ContainerID = ic.ID
|
|
c.ShmPath = ic.ShmPath
|
|
c.ShmPath = ic.ShmPath
|
|
c.MqueuePath = ic.MqueuePath
|
|
c.MqueuePath = ic.MqueuePath
|
|
|
|
+ } else {
|
|
|
|
+ ipc.HostIpc = c.hostConfig.IpcMode.IsHost()
|
|
|
|
+ if ipc.HostIpc {
|
|
|
|
+ c.ShmPath = "/dev/shm"
|
|
|
|
+ c.MqueuePath = "/dev/mqueue"
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
pid := &execdriver.Pid{}
|
|
pid := &execdriver.Pid{}
|
|
@@ -1402,7 +1408,7 @@ func (container *Container) setupIpcDirs() error {
|
|
}
|
|
}
|
|
|
|
|
|
func (container *Container) unmountIpcMounts() error {
|
|
func (container *Container) unmountIpcMounts() error {
|
|
- if container.hostConfig.IpcMode.IsContainer() {
|
|
|
|
|
|
+ if container.hostConfig.IpcMode.IsContainer() || container.hostConfig.IpcMode.IsHost() {
|
|
return nil
|
|
return nil
|
|
}
|
|
}
|
|
|
|
|