diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2020-10-02 07:53:37 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-02 07:53:37 -0400 |
commit | 08755e59b60df8e183a70cdbe90d7424a2fb91f4 (patch) | |
tree | fe9c360d6ed17e216612457ec592e3a93077fd33 /pkg | |
parent | ff3aa2b3d1b9765e0f09ed15dcf160065b54c889 (diff) | |
parent | 4f7da3274baed18c3eaf0a1329501d528e224436 (diff) | |
download | podman-08755e59b60df8e183a70cdbe90d7424a2fb91f4.tar.gz podman-08755e59b60df8e183a70cdbe90d7424a2fb91f4.tar.bz2 podman-08755e59b60df8e183a70cdbe90d7424a2fb91f4.zip |
Merge pull request #7456 from giuseppe/modprobe-fuse
spec: modprobe fuse with --device .*/fuse
Diffstat (limited to 'pkg')
-rw-r--r-- | pkg/specgen/generate/config_linux.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/pkg/specgen/generate/config_linux.go b/pkg/specgen/generate/config_linux.go index 1d5dcd8e7..fac02ad01 100644 --- a/pkg/specgen/generate/config_linux.go +++ b/pkg/specgen/generate/config_linux.go @@ -248,6 +248,13 @@ func addDevice(g *generate.Generator, device string) error { } g.Config.Mounts = append(g.Config.Mounts, devMnt) return nil + } else if src == "/dev/fuse" { + // if the user is asking for fuse inside the container + // make sure the module is loaded. + f, err := unix.Open(src, unix.O_RDONLY|unix.O_NONBLOCK, 0) + if err == nil { + unix.Close(f) + } } dev.Path = dst g.AddDevice(*dev) |