oci-executor: eval symlink for root

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
docker-18.09
Akihiro Suda 2018-06-07 16:04:55 +09:00
parent 5646fa3aa0
commit 43af03e59a
1 changed files with 4 additions and 1 deletions

View File

@ -73,7 +73,10 @@ func New(opt Opt) (executor.Executor, error) {
if err != nil {
return nil, err
}
// TODO: check that root is not symlink to fail early
root, err = filepath.EvalSymlinks(root)
if err != nil {
return nil, err
}
runtime := &runc.Runc{
Command: cmd,