executor/oci.GetUser(): remove unused context

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
v0.8
Sebastiaan van Stijn 2020-07-30 11:31:03 +02:00
parent 547db0f588
commit f26452a847
No known key found for this signature in database
GPG Key ID: 76698F39D527CE8C
3 changed files with 4 additions and 4 deletions

View File

@ -111,7 +111,7 @@ func (w *containerdExecutor) Run(ctx context.Context, id string, root cache.Moun
if err != nil {
return err
}
uid, gid, sgids, err = oci.GetUser(ctx, rootfsPath, meta.User)
uid, gid, sgids, err = oci.GetUser(rootfsPath, meta.User)
if err != nil {
lm.Unmount()
return err

View File

@ -14,7 +14,7 @@ import (
"github.com/pkg/errors"
)
func GetUser(ctx context.Context, root, username string) (uint32, uint32, []uint32, error) {
func GetUser(root, username string) (uint32, uint32, []uint32, error) {
// fast path from uid/gid
if uid, gid, err := ParseUIDGID(username); err == nil {
return uid, gid, nil, nil

View File

@ -212,7 +212,7 @@ func (w *runcExecutor) Run(ctx context.Context, id string, root cache.Mountable,
}
defer mount.Unmount(rootFSPath, 0)
uid, gid, sgids, err := oci.GetUser(ctx, rootFSPath, meta.User)
uid, gid, sgids, err := oci.GetUser(rootFSPath, meta.User)
if err != nil {
return err
}
@ -385,7 +385,7 @@ func (w *runcExecutor) Exec(ctx context.Context, id string, process executor.Pro
}
if process.Meta.User != "" {
uid, gid, sgids, err := oci.GetUser(ctx, state.Rootfs, process.Meta.User)
uid, gid, sgids, err := oci.GetUser(state.Rootfs, process.Meta.User)
if err != nil {
return err
}