Skip to content

Commit

Permalink
Merge pull request #8174 from rhatdan/errors
Browse files Browse the repository at this point in the history
Podman often reports OCI Runtime does not exist, even if it does
  • Loading branch information
openshift-merge-robot authored Oct 29, 2020
2 parents 1ce5ece + 0f191ad commit 228396a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions libpod/define/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,15 +141,15 @@ var (

// ErrOCIRuntimePermissionDenied indicates the OCI runtime attempted to invoke a command that returned
// a permission denied error
ErrOCIRuntimePermissionDenied = errors.New("OCI runtime permission denied error")
ErrOCIRuntimePermissionDenied = errors.New("OCI permission denied")

// ErrOCIRuntimeNotFound indicates the OCI runtime attempted to invoke a command
// that was not found
ErrOCIRuntimeNotFound = errors.New("OCI runtime command not found error")
ErrOCIRuntimeNotFound = errors.New("OCI not found")

// ErrOCIRuntimeUnavailable indicates that the OCI runtime associated to a container
// could not be found in the configuration
ErrOCIRuntimeUnavailable = errors.New("OCI runtime not available in the current configuration")
ErrOCIRuntimeUnavailable = errors.New("OCI unavailable")

// ErrConmonOutdated indicates the version of conmon found (whether via the configuration or $PATH)
// is out of date for the current podman version
Expand Down
4 changes: 2 additions & 2 deletions test/system/030-run.bats
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ load helpers
# ...but check the configured runtime engine, and switch to crun as needed
run_podman info --format '{{ .Host.OCIRuntime.Path }}'
if expr "$output" : ".*/crun"; then
err_no_such_cmd="Error: executable file.* not found in \$PATH: No such file or directory: OCI runtime command not found error"
err_no_exec_dir="Error: open executable: Operation not permitted: OCI runtime permission denied error"
err_no_such_cmd="Error: executable file.* not found in \$PATH: No such file or directory: OCI not found"
err_no_exec_dir="Error: open executable: Operation not permitted: OCI permission denied"
fi

tests="
Expand Down
2 changes: 1 addition & 1 deletion test/system/160-volumes.bats
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ EOF
# noexec option. This should fail.
# ARGH. Unfortunately, runc (used for cgroups v1) produces a different error
local expect_rc=126
local expect_msg='.* OCI runtime permission denied.*'
local expect_msg='.* OCI permission denied.*'
run_podman info --format '{{ .Host.OCIRuntime.Path }}'
if expr "$output" : ".*/runc"; then
expect_rc=1
Expand Down

0 comments on commit 228396a

Please sign in to comment.