summaryrefslogtreecommitdiff
path: root/pkg/adapter
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@pm.me>2019-10-18 13:40:21 -0400
committerMatthew Heon <matthew.heon@pm.me>2019-10-22 14:32:54 -0400
commitf60a814e4d9da87ac0dd5835b9a790a0b63f54b3 (patch)
tree1022a89d01e4f12e8ff8cd2b4a111073d262365f /pkg/adapter
parentd358840ebe02f45ef782546fc3f8369ff2870ea5 (diff)
downloadpodman-f60a814e4d9da87ac0dd5835b9a790a0b63f54b3.tar.gz
podman-f60a814e4d9da87ac0dd5835b9a790a0b63f54b3.tar.bz2
podman-f60a814e4d9da87ac0dd5835b9a790a0b63f54b3.zip
Add parsing for UID, GID in volume "o" option
Everything else is a flag to mount, but "uid" and "gid" are not. We need to parse them out of "o" and handle them separately. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Diffstat (limited to 'pkg/adapter')
-rw-r--r--pkg/adapter/runtime.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/pkg/adapter/runtime.go b/pkg/adapter/runtime.go
index 0706d4b6a..84d43c337 100644
--- a/pkg/adapter/runtime.go
+++ b/pkg/adapter/runtime.go
@@ -186,7 +186,12 @@ func (r *LocalRuntime) CreateVolume(ctx context.Context, c *cliconfig.VolumeCrea
}
if len(opts) != 0 {
- options = append(options, libpod.WithVolumeOptions(opts))
+ // We need to process -o for uid, gid
+ parsedOptions, err := shared.ParseVolumeOptions(opts)
+ if err != nil {
+ return "", err
+ }
+ options = append(options, parsedOptions...)
}
newVolume, err := r.NewVolume(ctx, options...)
if err != nil {