Make sure dev/fuse is created in container
Fixes #5849 If the host system does not have fuse enabled in the kernel config we will ignore the is not exist errors when trying to copy the device node from the host system into the container. Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
This commit is contained in:
parent
c6e60b57a2
commit
f06ca4fdd2
2 changed files with 23 additions and 6 deletions
|
@ -48,9 +48,12 @@ func InitializeMountNamespace(rootfs, console string, container *libcontainer.Co
|
|||
if err := setupBindmounts(rootfs, container.Mounts); err != nil {
|
||||
return fmt.Errorf("bind mounts %s", err)
|
||||
}
|
||||
if err := nodes.CopyN(rootfs, nodes.DefaultNodes); err != nil {
|
||||
if err := nodes.CopyN(rootfs, nodes.DefaultNodes, true); err != nil {
|
||||
return fmt.Errorf("copy dev nodes %s", err)
|
||||
}
|
||||
if err := nodes.CopyN(rootfs, nodes.AdditionalNodes, false); err != nil {
|
||||
return fmt.Errorf("copy additional dev nodes %s", err)
|
||||
}
|
||||
if err := SetupPtmx(rootfs, console, container.Context["mount_label"]); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue