From c6173a2b7cf2a132b9ceaf94ef106faab6801f29 Mon Sep 17 00:00:00 2001 From: Nicholas Tindle Date: Thu, 13 Feb 2025 20:03:08 -0600 Subject: [PATCH] Revert "Update platform-frontend-ci.yml" This reverts commit cd03f86a5c018f80aeb6ea4577eac7646e4d8a0e. --- .github/workflows/platform-frontend-ci.yml | 32 +++++++++++++--------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/.github/workflows/platform-frontend-ci.yml b/.github/workflows/platform-frontend-ci.yml index e104b5048f..80746ca3a2 100644 --- a/.github/workflows/platform-frontend-ci.yml +++ b/.github/workflows/platform-frontend-ci.yml @@ -96,6 +96,12 @@ jobs: run: | docker compose -f ../docker-compose.yml up -d + - name: Watch Docker Logs + run: | + docker compose -f ../docker-compose.yml logs -f & + LOGS_PID=$! + echo "LOGS_PID=$LOGS_PID" >> $GITHUB_ENV + - name: Install dependencies run: | yarn install --frozen-lockfile @@ -107,22 +113,22 @@ jobs: - name: Install Browser '${{ matrix.browser }}' run: yarn playwright install --with-deps ${{ matrix.browser }} - - name: Run tests with Docker logs + - name: Run tests timeout-minutes: 10 run: | - # Start streaming Docker logs and save its PID - docker compose -f ../docker-compose.yml logs -f & - LOGS_PID=$! - - # Run the tests yarn test --project=${{ matrix.browser }} - TEST_EXIT_CODE=$? - - # Kill the logs process - kill $LOGS_PID || true - - # Exit with the test's exit code - exit $TEST_EXIT_CODE + + - name: Stop Docker Logs + if: always() + run: | + if [ ! -z "$LOGS_PID" ]; then + kill $LOGS_PID || true + fi + + - name: Print Final Docker Compose logs + if: always() + run: | + docker compose -f ../docker-compose.yml logs - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }}