Skip to content

fix: remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime docker file#3286

Open
kapil27 wants to merge 1 commit intokubeflow:masterfrom
kapil27:remove-setcap-cap-net-bind
Open

fix: remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime docker file#3286
kapil27 wants to merge 1 commit intokubeflow:masterfrom
kapil27:remove-setcap-cap-net-bind

Conversation

@kapil27
Copy link
Contributor

@kapil27 kapil27 commented Mar 9, 2026

remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime …

sshd in the MPI runtime listens on port 2222 (non-privileged), so CAP_NET_BIND_SERVICE is not needed. Also removes libcap2-bin which was only installed to provide the setcap binary.

Fixes #3254

@google-oss-prow
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign terrytangyuan for approval. For more information see the Kubernetes Code Review Process.

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

Details 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

@kapil27 kapil27 changed the title fix: remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime … fix: remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime docker file Mar 9, 2026
…Dockerfiles

sshd in the MPI runtime listens on port 2222 (non-privileged),
so CAP_NET_BIND_SERVICE is not needed. Also removes libcap2-bin
which was only installed to provide the setcap binary.

Fixes kubeflow#3254

Signed-off-by: kapil27 <knema@redhat.com>
@kapil27 kapil27 force-pushed the remove-setcap-cap-net-bind branch from d8be6aa to 117d1fb Compare March 9, 2026 07:59
@kapil27 kapil27 marked this pull request as ready for review March 11, 2026 09:45
Copilot AI review requested due to automatic review settings March 11, 2026 09:45
@google-oss-prow google-oss-prow bot requested a review from jinchihe March 11, 2026 09:46
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR hardens the MPI runtime container images by removing an unnecessary Linux capability grant for sshd, aligning the Dockerfiles with the runtime’s non-privileged SSH port usage (2222) and reducing installed packages.

Changes:

  • Remove setcap CAP_NET_BIND_SERVICE from the MPI runtime Dockerfiles.
  • Drop libcap2-bin from image dependencies since setcap is no longer used.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
cmd/runtimes/mlx/Dockerfile Removes libcap2-bin and the setcap step, keeping the runtime aligned with non-privileged SSH usage.
cmd/runtimes/deepspeed/Dockerfile Same removal of libcap2-bin and setcap to avoid unnecessary capabilities.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove unnecessary setcap CAP_NET_BIND_SERVICE from MPI runtime Dockerfiles

2 participants