Skip to content

Commit

Permalink
[Feature] Print KubeRay logs in Buildkite runner when tests fail (#2690)
Browse files Browse the repository at this point in the history
Signed-off-by: LeoLiao123 <[email protected]>
  • Loading branch information
LeoLiao123 authored Dec 27, 2024
1 parent 9321b2d commit 2fb9465
Showing 1 changed file with 6 additions and 12 deletions.
18 changes: 6 additions & 12 deletions .buildkite/test-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,8 @@
- kind load docker-image kuberay/operator:nightly
- IMG=kuberay/operator:nightly make deploy
- kubectl wait --timeout=90s --for=condition=Available=true deployment kuberay-operator
# Run e2e tests
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2e
# Printing KubeRay operator logs
- kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay
# Run e2e tests and print KubeRay operator logs if tests fail
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2e || (kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay && exit 1)

- label: 'Test E2E rayservice (nightly operator)'
instance_size: large
Expand All @@ -29,10 +27,8 @@
- kind load docker-image kuberay/operator:nightly
- IMG=kuberay/operator:nightly make deploy
- kubectl wait --timeout=90s --for=condition=Available=true deployment kuberay-operator
# Run e2e tests
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2erayservice
# Printing KubeRay operator logs
- kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay
# Run e2e tests and print KubeRay operator logs if tests fail
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2erayservice || (kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay && exit 1)

- label: 'Test Autoscaler E2E (nightly operator)'
instance_size: large
Expand All @@ -47,7 +43,5 @@
- kind load docker-image kuberay/operator:nightly
- IMG=kuberay/operator:nightly make deploy
- kubectl wait --timeout=90s --for=condition=Available=true deployment kuberay-operator
# Run e2e tests
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2eautoscaler
# Printing KubeRay operator logs
- kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay
# Run e2e tests and print KubeRay operator logs if tests fail
- KUBERAY_TEST_TIMEOUT_SHORT=1m KUBERAY_TEST_TIMEOUT_MEDIUM=5m KUBERAY_TEST_TIMEOUT_LONG=10m go test -timeout 30m -v ./test/e2eautoscaler || (kubectl logs --tail -1 -l app.kubernetes.io/name=kuberay && exit 1)

0 comments on commit 2fb9465

Please sign in to comment.