Skip to content

Commit 04c8fa9

Browse files
author
Evan Anderson
authored
Wait for loadbalancer to be "ready" before testing (#333)
* Wait for loadbalancer to be "ready" before testing * Include library for wait_until_service_has_external_http_address * Can't make the function wait until things are working, move the wait into main
1 parent 11d150e commit 04c8fa9

2 files changed

Lines changed: 7 additions & 0 deletions

File tree

test/e2e-library-deployments.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ function deploy_contour() {
4545
echo ">> Waiting for Contour operator deployment to be available"
4646
kubectl wait deploy --for=condition=Available --timeout=120s -n "contour-operator" -l '!job-name'
4747

48+
# TODO: kind-ify this to support both LB and NodePort like Istio
49+
4850
ko resolve -f ./third_party/contour/gateway/ | \
4951
sed 's/LoadBalancerService/NodePortService/g' | \
5052
kubectl apply -f -

test/e2e-tests.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ initialize "$@" --skip-istio-addon
2828

2929
deploy_gateway_for istio
3030

31+
# When running in a "real" cluster, we need to wait for the loadbalancer IP to
32+
# be assigned before running e2e tests. Due to import dependencies, we can't
33+
# run this in deploy_gateway_for.
34+
wait_until_service_has_external_http_address istio-system istio-ingressgateway
35+
3136
# Run the tests
3237
header "Running e2e tests with all available Gateway API vendors installed"
3338
e2e_istio

0 commit comments

Comments
 (0)