-
Notifications
You must be signed in to change notification settings - Fork 562
Lock down package server runtime environment #1073
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
Lock down package server runtime environment #1073
Conversation
Hi @javanthropus. Thanks for your PR. I'm waiting for a operator-framework or openshift member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the 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. |
/ok-to-test |
/retest |
Thanks @javanthropus ! /lgtm |
/hold Sorry, I thought you had removed the default runAsUser. Could you remove that as well? If you can explain more about your deploy target we can maybe find a better place to put those values? It might make sense for our (OpenShift randomizes uids on deployment, so setting this is actually not what we want for OCP releases) |
The clusters we're building have a default pod security policy applied such that pods are not allowed to run as root and their root filesystems are mounted read-only. Another way to address this problem would have been to apply a pod security policy and corresponding role and role binding for packageserver to use; however, since pod security policies are still a beta resource, I figured that locking down packageserver was the safer bet. Plus, running it this way is a bit safer should there be a vulnerability in it. If there is a different file in which to place the default value, I'll move it over there. I'm not familiar enough with this project to know which is the best to choose. |
I've been doing more testing against our clusters, and it actually looks like this change may not be necessary in the first place. The package server pods run with the At this point, I'm not sure anymore what was broken in my test cluster that made me think I needed to make this change. I'm going to do more testing, and I'll close this PR if it really proves to be unnecessary, unless you would like to keep the changes for the security benefits alone. |
I tested things out with the stock 0.12.0 release on a fresh cluster, and none of my changes were necessary to work around the pod security policies. Sadly, our most permissive policy is used, but that's a result of how the policy admission controller works and the broad permissions granted to the service account used by packageserver. I would still like to see this MR accepted since it still helps reduce the attack surface of packageserver. If you agree, let me know where to move that default |
/retest |
I do not believe the changes in this PR should cause the test failures being reported. Please let me know if I'm wrong about that though. |
/retest |
/hold cancel |
/retest |
1 similar comment
/retest |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ecordell, javanthropus, jpeeler 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 |
/retest Please review the full test history for this PR and help us cut down flakes. |
10 similar comments
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
Please stop the automatic re-tries. The failing tests are clearly not going to pass without manual intervention. These failure notices are becoming a problem. |
/retest Please review the full test history for this PR and help us cut down flakes. |
14 similar comments
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
Description of the change:
This PR modifes the package server component's deployment manifest's pods to:
Motivation for the change:
At Indeed we're using restrictive pod security policies that among other things prevent pods running as root and marks them to have read-only root filesystems.
Reviewer Checklist
/docs