From 3b8df5ad1ae729d1c8b9b8c5f567a061fefcc730 Mon Sep 17 00:00:00 2001 From: webbrain-one <295484252+webbrain-one@users.noreply.github.com> Date: Sat, 1 Aug 2026 13:10:08 +0300 Subject: [PATCH] fix: e2e tests check on fork PRs Work around the AWS credentials bug causing failures on fork PRs. Ref: aws-actions/configure-aws-credentials#564 Fixes #205 --- .github/workflows/build.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bc006e2..8a30488 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -106,6 +106,7 @@ jobs: "$GITHUB_WORKSPACE/test-files/scripts/test-local-e2e.sh" - name: configure aws credentials + if: ${{ github.event.pull_request.head.repo.fork == false }} # Configures AWS credential and region environment variables for use in other GitHub Actions. # The environment variables will be detected by both the AWS SDKs and the AWS CLI to determine the credentials and region to use for AWS API calls. # More on this action at https://github.com/aws-actions/configure-aws-credentials @@ -115,6 +116,7 @@ jobs: aws-region: us-west-2 - name: prepare to run remote end-to-end test + if: ${{ github.event.pull_request.head.repo.fork == false }} run: | cd "$GITHUB_WORKSPACE/examples/basic" npm i @@ -122,6 +124,7 @@ jobs: npm install --save file://../../serverless-aws-static-file-handler-0.0.0.tgz - name: run remote end-to-end test + if: ${{ github.event.pull_request.head.repo.fork == false }} run: | cd "$GITHUB_WORKSPACE/examples/basic" echo "Deploying serverless stage $SERVERLESS_STAGE" @@ -153,7 +156,7 @@ jobs: - name: cleanup remote end-to-end test (destroy serverless stack) # Run this step even if the prior one failed (to clean up) - if: ${{ always() }} + if: ${{ always() && github.event.pull_request.head.repo.fork == false }} run: | cd "$GITHUB_WORKSPACE/examples/basic" echo "Destroying serverless stage $SERVERLESS_STAGE"