Skip to content
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

[RayService] Add RayService alb ingress CR #1169

Merged
merged 4 commits into from
Jun 15, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/guidance/ingress.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ eksctl get cluster ${YOUR_EKS_CLUSTER} # Check subnets on the EKS cluster

# Step 4: Create an ALB ingress. When an ingress with proper annotations creates,
# AWS Load Balancer controller will reconcile a ALB (not in AWS EKS cluster).
# For RayService, you can use ray-operator/config/samples/ray_v1alpha1_rayservice-alb-ingress.yaml
sihanwang41 marked this conversation as resolved.
Show resolved Hide resolved
kubectl apply -f ray-operator/config/samples/alb-ingress.yaml

# Step 5: Check ingress created by Step 4.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
apiVersion: networking.k8s.io/v1
sihanwang41 marked this conversation as resolved.
Show resolved Hide resolved
kind: Ingress
metadata:
name: ray-cluster-ingress
annotations:
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/tags: Environment=dev,Team=test
# See `ingress.md` for more details about how to choose subnets.
alb.ingress.kubernetes.io/subnets: subnet-d9d4ff92, subnet-0c0209db843c9fd72
alb.ingress.kubernetes.io/target-type: ip
# Health Check Settings
sihanwang41 marked this conversation as resolved.
Show resolved Hide resolved
alb.ingress.kubernetes.io/healthcheck-protocol: HTTP
alb.ingress.kubernetes.io/healthcheck-port: traffic-port
sihanwang41 marked this conversation as resolved.
Show resolved Hide resolved
alb.ingress.kubernetes.io/healthcheck-path: /-/routes
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the behavior if this health check fails? Does traffic simply stop flowing to the pod, or does the pod get restarted?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, traffic will stop sending traffic to the pod. (if there is only one pod which is unhealthy, the traffic will still be sent to that pod.)
No operation on the pod. it still relies on the kuberay operation to take care of it.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good, that makes sense.

spec:
ingressClassName: alb
rules:
- http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: rayservice-sample-serve-svc # Serve service
port:
number: 8000 # default HTTP port number for serving requests