Skip to content

Commit

Permalink
Merge pull request #13031 from giuseppe/drop-permission-check-privile…
Browse files Browse the repository at this point in the history
…ged-rootless-devices

rootless: drop permission check for devices
  • Loading branch information
openshift-merge-robot authored Jan 27, 2022
2 parents 09589fc + 6336e1f commit 0d96c46
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions pkg/specgen/generate/config_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,6 @@ func addPrivilegedDevices(g *generate.Generator) error {
if _, found := mounts[d.Path]; found {
continue
}
st, err := os.Stat(d.Path)
if err != nil {
if err == unix.EPERM {
continue
}
return err
}
// Skip devices that the user has not access to.
if st.Mode()&0007 == 0 {
continue
}
newMounts = append(newMounts, devMnt)
}
g.Config.Mounts = append(newMounts, g.Config.Mounts...)
Expand Down

0 comments on commit 0d96c46

Please sign in to comment.