-
Notifications
You must be signed in to change notification settings - Fork 151
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
fix: Prevent containers from running as root by removing unnecessary anyuid SCC bindings #1460
fix: Prevent containers from running as root by removing unnecessary anyuid SCC bindings #1460
Conversation
/test opendatahub-operator-e2e |
a610fb2
to
7af1f90
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1460 +/- ##
==========================================
- Coverage 19.90% 19.88% -0.02%
==========================================
Files 161 160 -1
Lines 10833 10818 -15
==========================================
- Hits 2156 2151 -5
+ Misses 8448 8440 -8
+ Partials 229 227 -2 ☔ View full report in Codecov by Sentry. |
/retest |
@@ -62,7 +61,6 @@ func (s *componentHandler) NewComponentReconciler(ctx context.Context, mgr ctrl. | |||
WithAction(initialize). | |||
WithAction(devFlags). | |||
WithAction(configureDependencies). | |||
WithAction(security.NewUpdatePodSecurityRoleBindingAction(serviceAccounts)). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not following this in the entirety, but for Notebooks we really don't need to have anyuid scc, certainly not after https://issues.redhat.com/browse/RHOAIENG-72 got in, and IMO even before that we were good with any uid.
cc @opendatahub-io/notebook-devs for heads-up!
/test opendatahub-operator-e2e |
a3aa31f
to
b094cc0
Compare
/uncc @Sara4994 |
a2a65f2
to
b094cc0
Compare
b094cc0
to
60c6daa
Compare
@@ -91,7 +90,6 @@ func (s *componentHandler) NewComponentReconciler(ctx context.Context, mgr ctrl. | |||
WithAction(initialize). | |||
WithAction(devFlags). | |||
WithAction(configureDependencies). | |||
WithAction(security.NewUpdatePodSecurityRoleBindingAction(serviceAccounts)). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is NewUpdatePodSecurityRoleBindingAction
is not more in use, we can probably remove it
… and the security folder containing both, as they are no longer needed.
/lgtm |
/retest |
/test opendatahub-operator-e2e |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: lburgazzoli 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 |
71f79e2
into
opendatahub-io:main
Description
This PR addresses the security concern of containers running with root privileges by removing the following ServiceAccounts from default
RoleBindings
granting theanyuid
SCC:These changes help ensure that containers run with non-root user privileges and comply with security policies. Additionally, this makes the default RoleBinding that assigns the
default
ServiceAccount to theanyuid
SCC unnecessary:How Has This Been Tested?
Screenshot or short clip
Merge criteria