Skip to content

add: raycluster oauth mutating webhook #507

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

Closed

Conversation

VanillaSpoon
Copy link
Contributor

@VanillaSpoon VanillaSpoon commented Apr 11, 2024

Issue link

https://issues.redhat.com/browse/RHOAIENG-1991

What changes have been made

Add Mutating Webhook to add OAuth SideCar to RayCluster

Verification steps

Setup environment.
Run the Codeflare-Operator from main
Build and deploy raycluster_webhook.

  • From within src:
    • podman build <quay.io/user/repo:version> .
    • podman push <quay.io/user/repo:version
  • From within config
    -kubectl apply -f deployment.yaml

Ensure the webhook is running in default namespace (will be changing this)

From the sdk, create a raycluster

  • Ensure the raycluster is deployed correctly
  • Inspect the raycluster yaml to enusre the oauth configuraitons have been applied
  • Inspect the raycluster head node and ensure the oauth is running alongside it.

Checks

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

Sorry, something went wrong.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Copy link

openshift-ci bot commented Apr 11, 2024

[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 astefanutti for approval. For more information see the Kubernetes Code Review Process.

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

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

Verified

This commit was signed with the committer’s verified signature.
wooorm Titus

Verified

This commit was signed with the committer’s verified signature.
wooorm Titus
Path: "/spec/headGroupSpec/template/spec/containers/-",
Value: newOAuthSidecar,
})

Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
tlsSecretVolume := corev1.Volume{
Name: "proxy-tls-secret",
VolumeSource: corev1.VolumeSource{
Secret: &corev1.SecretVolumeSource{
SecretName: rayclusterName + "-proxy-tls-secret",
},
},
}
// Patch to add new volume
patches = append(patches, patchOperation{
Op: "add",
Path: "/spec/headGroupSpec/template/spec/volumes/-",
Value: tlsSecretVolume,
})

Missing the tls-secret volume for the Volume Mount

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Great spot, thanks @Bobbins228

Verified

This commit was signed with the committer’s verified signature.
wooorm Titus
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.

None yet

2 participants