mirror of
https://github.com/containers/podman.git
synced 2025-08-06 03:19:52 +08:00
Allow (but ignore) Cached and Delegated volume options
These are only used on OS X Docker, and ignored elsewhere - but since they are ignored, they're guaranteed to be safe everywhere, and people are using them. Fixes: #3340 Signed-off-by: Matthew Heon <matthew.heon@pm.me>
This commit is contained in:
@ -20,26 +20,22 @@ func ProcessOptions(options []string) []string {
|
||||
foundbind, foundrw, foundro bool
|
||||
rootProp string
|
||||
)
|
||||
|
||||
for _, opt := range options {
|
||||
switch opt {
|
||||
case "bind", "rbind":
|
||||
foundbind = true
|
||||
break
|
||||
case "ro":
|
||||
foundro = true
|
||||
case "rw":
|
||||
foundrw = true
|
||||
case "private", "rprivate", "slave", "rslave", "shared", "rshared":
|
||||
rootProp = opt
|
||||
}
|
||||
}
|
||||
if !foundbind {
|
||||
options = append(options, "rbind")
|
||||
}
|
||||
for _, opt := range options {
|
||||
switch opt {
|
||||
case "rw":
|
||||
foundrw = true
|
||||
case "ro":
|
||||
foundro = true
|
||||
case "private", "rprivate", "slave", "rslave", "shared", "rshared":
|
||||
rootProp = opt
|
||||
}
|
||||
}
|
||||
if !foundrw && !foundro {
|
||||
options = append(options, "rw")
|
||||
}
|
||||
|
Reference in New Issue
Block a user