diff --git a/.github/workflows/canary-integration-test.yml b/.github/workflows/canary-integration-test.yml index f8bdc4766..56908cce5 100644 --- a/.github/workflows/canary-integration-test.yml +++ b/.github/workflows/canary-integration-test.yml @@ -972,6 +972,8 @@ jobs: kubectl delete -f tests/manifests/test-object.yaml yq write -i tests/manifests/test-object.yaml "spec.security.kms.connectionDetails.VAULT_SECRET_ENGINE" transit timeout 120 bash -c 'while kubectl -n rook-ceph get cephobjectstore my-store; do echo "waiting for objectstore my-store to delete"; sleep 5; done' + echo "wait for rgw pod to be deleted" + kubectl wait --for=delete pod -l app=rook-ceph-rgw -n rook-ceph --timeout=100s kubectl create -f tests/manifests/test-object.yaml tests/scripts/validate_cluster.sh rgw tests/scripts/deploy-validate-vault.sh validate_rgw diff --git a/tests/scripts/deploy-validate-vault.sh b/tests/scripts/deploy-validate-vault.sh index da10a1a20..df793a07e 100755 --- a/tests/scripts/deploy-validate-vault.sh +++ b/tests/scripts/deploy-validate-vault.sh @@ -167,7 +167,9 @@ function deploy_vault { } function validate_rgw_token { - RGW_POD=$(kubectl -n rook-ceph get pods -l app=rook-ceph-rgw | awk 'FNR == 2 {print $1}') + echo "wait for rgw pod to be ready" + kubectl wait --for=condition=ready pod -l app=rook-ceph-rgw -n rook-ceph --timeout=100s + RGW_POD=$(kubectl get pods -l app=rook-ceph-rgw -n rook-ceph --no-headers -o custom-columns=":metadata.name") RGW_TOKEN_FILE=$(kubectl -n rook-ceph describe pods "$RGW_POD" | grep "rgw-crypt-vault-token-file" | cut -f2- -d=) VAULT_PATH_PREFIX=$(kubectl -n rook-ceph describe pods "$RGW_POD" | grep "rgw-crypt-vault-prefix" | cut -f2- -d=) VAULT_TOKEN=$(kubectl -n rook-ceph exec $RGW_POD -- cat $RGW_TOKEN_FILE)