forked from ray-project/ray
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[kubernetes][release] K8s release test instructions (ray-project#16662)
- Loading branch information
1 parent
c318293
commit 257d072
Showing
8 changed files
with
62 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# ray-k8s-tests | ||
|
||
How to run | ||
1. Configure kubectl and Helm 3 to access a K8s cluster. | ||
2. `git checkout releases/<release version>` | ||
3. You might have to locally pip install the Ray wheel for the relevant commit (or pip install -e) in a conda env, see Ray client note below. | ||
4. cd to this directory | ||
3. `IMAGE=rayproject/ray:<release version> bash k8s_ci.sh` | ||
|
||
This runs three tests and does the necessary resource creation/teardown. The tests typically take about 15 minutes to finish. | ||
Notes: | ||
1. Your Ray cluster should be able to accomodate 30 1-CPU pods to run all of the tests. | ||
2. These tests use basic Ray client functionality -- your locally installed Ray version may need to be updated to match the one in the release image. | ||
3. The tests do a poor job of Ray client port-forwarding process clean-up -- if a test fails, it's possible there might be a port-forwarding process stuck running in the background. To identify the rogue process run `ps aux | grep "port-forward"`. Then `kill` it. | ||
4. There are some errors that will appear on the screen during the run -- that's normal, error recovery is being tested. | ||
|
||
To run any of the three individual tests, substitute in step 4 above `k8s-test.sh` or `helm-test.sh` or `k8s-test-scale.sh`. | ||
It's the last of these that needs 30 1-cpu pods. 10 is enough for either of the other two. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/bash | ||
set -x | ||
kubectl create namespace helm-test | ||
kubectl create namespace helm-test2 | ||
KUBERNETES_OPERATOR_TEST_NAMESPACE=helm-test KUBERNETES_OPERATOR_TEST_IMAGE="$IMAGE" python ../../python/ray/tests/kubernetes_e2e/test_helm.py | ||
kubectl delete namespace helm-test | ||
kubectl delete namespace helm-test2 | ||
kubectl delete -f ../../deploy/charts/ray/crds/cluster_crd.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/bash | ||
set -x | ||
kubectl create namespace scale-test | ||
kubectl create namespace scale-test2 | ||
KUBERNETES_OPERATOR_TEST_NAMESPACE=scale-test KUBERNETES_OPERATOR_TEST_IMAGE="$IMAGE" python ../../python/ray/tests/kubernetes_e2e/test_k8s_operator_scaling.py | ||
kubectl -n scale-test delete --all rayclusters | ||
kubectl -n scale-test2 delete --all rayclusters | ||
kubectl delete -f ../../deploy/components/operator_cluster_scoped.yaml | ||
kubectl delete namespace scale-test | ||
kubectl delete namespace scale-test2 | ||
kubectl delete -f ../../deploy/charts/ray/crds/cluster_crd.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
set -x | ||
kubectl create namespace basic-test | ||
kubectl apply -f ../../deploy/charts/ray/crds/cluster_crd.yaml | ||
KUBERNETES_OPERATOR_TEST_NAMESPACE=basic-test KUBERNETES_OPERATOR_TEST_IMAGE="$IMAGE" python ../../python/ray/tests/kubernetes_e2e/test_k8s_operator_basic.py | ||
kubectl -n basic-test delete --all rayclusters | ||
kubectl -n basic-test delete deployment ray-operator | ||
kubectl delete namespace basic-test | ||
kubectl delete -f ../../deploy/charts/ray/crds/cluster_crd.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
set -x | ||
IMAGE="$IMAGE" bash k8s-test.sh | ||
IMAGE="$IMAGE" bash helm-test.sh | ||
IMAGE="$IMAGE" bash k8s-test-scale.sh |