-
Notifications
You must be signed in to change notification settings - Fork 323
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
NET-5947 Add NET_BIND_SERVICE capability in security context for api-gateway pod on OpenShift #3070
Conversation
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 don't really like it but I understand why it is needed. Approve!
@@ -19,7 +18,7 @@ import ( | |||
) | |||
|
|||
const ( | |||
allCapabilities = "all" | |||
allCapabilities = "ALL" |
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.
This was causing an odd merge when the OpenShift controller added ALL
alongside our all
since they're not equal strings, resulting in
drop:
- ALL
- all
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.
650cbbc
to
1b639af
Compare
Why this change is needed:
This capability became a requirement for consul-dataplane, which api-gateway uses under the hood, as of hashicorp/consul-dataplane#238. Since the
securityContext
created for each consul-dataplanePod
was not requesting theNET_BIND_SERVICE
capability specifically when deploying onto OpenShift, it was not being granted, and thePod
was failing to start with a permission denied error.Changes proposed in this PR:
NET_BIND_SERVICE
capability to thesecurityContext
for each api-gatewayPod
How I've tested this PR:
securityContext
is always set appropriately onPod
Pod
starts up correctly nowHow I expect reviewers to test this PR:
Checklist: