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

Use security context to set up the default seccomp profile for spod pod and security-profiles-operator container #1239

Conversation

ccojocar
Copy link
Contributor

@ccojocar ccojocar commented Oct 17, 2022

What type of PR is this?

/kind clean-up

What this PR does / why we need it:

Use security context to set up the default seccomp profile for spod pod and security-profiles-operator container.

Which issue(s) this PR fixes:

security context is a more up to date way to setup the seccomp profile instead of the anotations.

Does this PR have test?

Special notes for your reviewer:

Does this PR introduce a user-facing change?

Use security context to set up the default seccomp profile for spod pod and security-profiles-operator container.

@k8s-ci-robot k8s-ci-robot added do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Oct 17, 2022
@k8s-ci-robot
Copy link
Contributor

Hi @ccojocar. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Oct 17, 2022
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Oct 17, 2022
@ccojocar
Copy link
Contributor Author

/test all

@k8s-ci-robot
Copy link
Contributor

@ccojocar: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/test all

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.

@saschagrunert
Copy link
Member

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Oct 17, 2022
@ccojocar
Copy link
Contributor Author

ccojocar commented Oct 17, 2022

This seems like a flaky unit test:

--- FAIL: TestGetOperatorNamespace (0.00s)
    --- PASS: TestGetOperatorNamespace/invalid_one (0.00s)
    --- FAIL: TestGetOperatorNamespace/Valid_one (0.00s)

@k8s-ci-robot
Copy link
Contributor

@ccojocar: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test pull-security-profiles-operator-build
  • /test pull-security-profiles-operator-build-image
  • /test pull-security-profiles-operator-test-e2e
  • /test pull-security-profiles-operator-test-unit
  • /test pull-security-profiles-operator-verify

Use /test all to run all jobs.

In response to this:

/test al

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.

@ccojocar
Copy link
Contributor Author

/test all

@saschagrunert
Copy link
Member

Yes I can re-kick the tests once the others finished. Do you need this change as part of v0.5.0, @ccojocar ?

@ccojocar
Copy link
Contributor Author

It would be great to have it as part of v0.5.0 since we have some issues on cri-o runtime with the current way of setting the seccomp profile.

@saschagrunert saschagrunert mentioned this pull request Oct 17, 2022
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ccojocar, saschagrunert

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

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Oct 17, 2022
@ccojocar
Copy link
Contributor Author

I think the issue is that cri-o runtime requires the profile path to be prefix with localhost while other runtime such as docker doesn't: https://github.com/cri-o/cri-o/blob/main/internal/config/seccomp/seccomp.go#L240

I am not sure what's the best way to go about this. How can we detect the runtime and configure the path accordingly?

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 17, 2022
@saschagrunert
Copy link
Member

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 17, 2022
@k8s-ci-robot k8s-ci-robot merged commit c29644e into kubernetes-sigs:main Oct 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants