Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test/system/410-selinux: fix for newer runc #14613

Merged
merged 1 commit into from
Jun 16, 2022

Conversation

kolyshkin
Copy link
Contributor

With runc 1.1, we have the following failure:

 # #|     FAIL: podman emits useful diagnostic on failure
 # #| expected: 'Error.*: OCI runtime error: .*: failed to set /proc/self/attr/keycreate on procfs' (using expr)
 # #|   actual: 'Error: OCI runtime error: runc: runc create failed: unable to start container process: error during container init: write /proc/self/attr/keycreate: invalid argument'

which is caused by the fact that runc 1.1 uses newer opencontainers/selinux
package, which changes custom errors to standard os.PathError instances (so
that they can be unwrapped if needed).

Fix the test case accordingly. NOT TESTED.

Does this PR introduce a user-facing change?

NONE

With runc 1.1, we have the following failure:

 # #|     FAIL: podman emits useful diagnostic on failure
 # #| expected: 'Error.*: OCI runtime error: .*: failed to set /proc/self/attr/keycreate on procfs' (using expr)
 # #|   actual: 'Error: OCI runtime error: runc: runc create failed: unable to start container process: error during container init: write /proc/self/attr/keycreate: invalid argument'

which is caused by the fact that runc 1.1 uses newer opencontainers/selinux
package, which changes custom errors to standard os.PathError instances (so
that they can be unwrapped if needed).

Fix the test case accordingly.

Signed-off-by: Kir Kolyshkin <[email protected]>
Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks.

@edsantiago PTAL

@edsantiago
Copy link
Member

/lgtm
/hold

Thanks @kolyshkin

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 16, 2022
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 16, 2022
@Luap99
Copy link
Member

Luap99 commented Jun 16, 2022

/approve
/hold cancel

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 16, 2022
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 16, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kolyshkin, Luap99

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 16, 2022
@openshift-ci openshift-ci bot merged commit e3a0dea into containers:main Jun 16, 2022
@lsm5
Copy link
Member

lsm5 commented Jun 23, 2022

/cherrypick v4.1.1.-rhel

@openshift-cherrypick-robot
Copy link
Collaborator

@lsm5: cannot checkout v4.1.1.-rhel: error checking out v4.1.1.-rhel: exit status 1. output: error: pathspec 'v4.1.1.-rhel' did not match any file(s) known to git

In response to this:

/cherrypick v4.1.1.-rhel

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@lsm5
Copy link
Member

lsm5 commented Jun 23, 2022

/cherrypick v4.1.1-rhel

@openshift-cherrypick-robot
Copy link
Collaborator

@lsm5: new pull request created: #14710

In response to this:

/cherrypick v4.1.1-rhel

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

edsantiago added a commit to edsantiago/libpod that referenced this pull request Aug 16, 2022
Followup to containers#14613, which was never actually tested until this
week in RHEL8 gating tests (see issue containers#15337).

 * add missing backslash in '|' expression
 * allow extra text after error (e.g., "invalid argument")

No way to test this until it makes its way into RHEL8,
so, fingers crossed.

Signed-off-by: Ed Santiago <[email protected]>
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 21, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. release-note-none
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants