Skip to content

Auto-Detect kuberay-operator namespace #678

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

Merged

Conversation

szaher
Copy link
Member

@szaher szaher commented Apr 14, 2025

Enable auto-detection of the namespace where
kuberay-operator is deployed so we can enable network traffic between raycluster namespace and kuberay-operator namespace.

Issue link

RHOAIENG-22373

What changes have been made

auot-detect the namespace where kuberay-operator is deployed to enable correct configuration of network policies for ray clusters

Verification steps

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • Testing is not required for this change

Enable auto-detection of the namespace where
kuberay-operator is deployed so we can enable network
traffic between raycluster namespace and kuberay-operator
namespace.

Signed-off-by: Saad Zaher <[email protected]>
@chipspeak chipspeak self-requested a review April 14, 2025 15:46
Copy link
Contributor

@chipspeak chipspeak left a comment

Choose a reason for hiding this comment

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

LGTM and thanks Saad!

@@ -319,6 +327,32 @@ func isMTLSEnabled(cfg *config.KubeRayConfiguration) bool {
return cfg == nil || ptr.Deref(cfg.MTLSEnabled, true)
}

// getKubeRayOperatorNamespace tries to get the namespace of the KubeRay operator
func (r *RayClusterReconciler) getKubeRayOperatorNamespace(ctx context.Context) (string, error) {

Choose a reason for hiding this comment

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

do we want to cover this by a small unit test or dyt it's ok?

Copy link
Member Author

Choose a reason for hiding this comment

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

@openshift-ci openshift-ci bot removed the lgtm label Apr 15, 2025
@openshift-ci openshift-ci bot added the lgtm label Apr 15, 2025
Copy link

openshift-ci bot commented Apr 15, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: chipspeak, kryanbeane

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:
  • OWNERS [chipspeak,kryanbeane]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

1 similar comment
Copy link

openshift-ci bot commented Apr 15, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: chipspeak, kryanbeane

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:
  • OWNERS [chipspeak,kryanbeane]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 35e76cb into project-codeflare:main Apr 15, 2025
8 checks passed
@szaher szaher deleted the fix-network-policies branch April 15, 2025 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants