mirror of
https://github.com/containers/podman.git
synced 2025-05-17 15:18:43 +08:00
Fix parsing of paths for unmask
This fixes an issue where multiple paths separated by a colon were treated as a single path, contrary to what docs say and unlike how mask option works. Test was updated with a case that fails without this commit. Signed-off-by: Šimon Škoda <ver4a@uncontrol.me>
This commit is contained in:
@ -739,9 +739,7 @@ func FillOutSpecGen(s *specgen.SpecGenerator, c *entities.ContainerCreateOptions
|
||||
return fmt.Errorf("invalid systempaths option %q, only `unconfined` is supported", val)
|
||||
}
|
||||
case "unmask":
|
||||
if hasVal {
|
||||
s.ContainerSecurityConfig.Unmask = append(s.ContainerSecurityConfig.Unmask, val)
|
||||
}
|
||||
s.ContainerSecurityConfig.Unmask = append(s.ContainerSecurityConfig.Unmask, strings.Split(val, ":")...)
|
||||
case "no-new-privileges":
|
||||
noNewPrivileges := true
|
||||
if hasVal {
|
||||
|
Reference in New Issue
Block a user