Merge pull request #5020 from baude/bindingtestrootless

Bindingtestrootless
This commit is contained in:
OpenShift Merge Robot
2020-01-30 15:24:51 -08:00
committed by GitHub
2 changed files with 9 additions and 0 deletions

View File

@ -62,6 +62,12 @@ func (b *bindingTest) runPodman(command []string) *gexec.Session {
} else {
cmd = append(cmd, "--runroot", b.runRoot)
}
val, ok = os.LookupEnv("TEMPDIR")
if ok {
cmd = append(cmd, "--tmpdir", val)
} else {
cmd = append(cmd, "--tmpdir", b.tempDirPath)
}
val, ok = os.LookupEnv("STORAGE_DRIVER")
if ok {
cmd = append(cmd, "--storage-driver", val)

View File

@ -200,6 +200,9 @@ can_use_shortcut ()
if (argv == NULL)
return false;
if (strstr (argv[0], "podman") == NULL)
return false;
for (argc = 0; argv[argc]; argc++)
{
if (argc == 0 || argv[argc][0] == '-')