From 0b5cdcb404e8daf156c8c9045c4e305cb12a5867 Mon Sep 17 00:00:00 2001 From: Eric Promislow Date: Wed, 15 May 2024 10:08:34 -0700 Subject: [PATCH] WIP - add debug stmts to integration tests --- .github/workflows/fossa.yaml | 6 +++--- scripts/integration-test | 9 ++++++--- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/fossa.yaml b/.github/workflows/fossa.yaml index 78378a5f3..5a60a3fb9 100644 --- a/.github/workflows/fossa.yaml +++ b/.github/workflows/fossa.yaml @@ -20,15 +20,15 @@ jobs: uses: rancher-eio/read-vault-secrets@main with: secrets: | - secret/data/github/repo/${{ github.repository }}/fossa/credentials token | FOSSA + secret/data/github/repo/${{ github.repository }}/fossa/credentials token | FOSSA_API_KEY - name: Checkout Repo uses: actions/checkout@v4 - name: Run FOSSA Analyze uses: fossas/fossa-action@v1.3.3 with: - api-key: ${{ env.FOSSA }} + api-key: ${{ env.FOSSA_API_KEY }} - name: Run FOSSA test uses: fossas/fossa-action@v1.3.3 with: - api-key: ${{ env.FOSSA }} + api-key: ${{ env.FOSSA_API_KEY }} run-tests: true diff --git a/scripts/integration-test b/scripts/integration-test index 7911a2f6a..b709d7b7d 100755 --- a/scripts/integration-test +++ b/scripts/integration-test @@ -9,6 +9,8 @@ export CATTLE_FEATURES="harvester=false" cd $(dirname $0)/../ echo "Starting Rancher Server" +which entrypoint.sh +cat $(which entrypoint.sh) entrypoint.sh >./rancher.log 2>&1 & RANCHER_PID=$! @@ -18,8 +20,9 @@ while ! curl -sf http://localhost:80/healthz >/dev/null 2>&1; do ((RETRIES++)) if (( RETRIES > 300 )) ; then echo "Timed out waiting for Rancher to restart" + kill -9 $RANCHER_PID fi - echo "Try # $RETRIES waiting for rancher" + echo "Try #$RETRIES waiting for rancher" sleep 2 done @@ -39,10 +42,10 @@ echo "Webhook deployed" kill ${TAIL_PID} # Wait for helm operation to complete and save rancher-webhook release info before we kill rancher and the cluster. -while +while status=$(kubectl get apps.catalog.cattle.io -n cattle-system rancher-webhook -o jsonpath="{@.status.summary.state}") [[ "$status" != "deployed" ]] -do +do echo "Waiting for helm operation to finish, current status $status" sleep 2 done