File tree Expand file tree Collapse file tree 1 file changed +45
-0
lines changed Expand file tree Collapse file tree 1 file changed +45
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Build SDK
2+ on :
3+ pull_request_review :
4+ types : [ submitted ]
5+ branches : [ main ]
6+
7+ concurrency :
8+ group : start-pull-request-build-${{ github.ref }}
9+ cancel-in-progress : true
10+
11+ env :
12+ IAM_ROLE_ARN : ' arn:aws:iam::088667348242:role/AwsSdkJsV3GitHubRole'
13+ DOWNLOAD_FOLDER : ' .build-scripts/'
14+ SCRIPT_LOCATION : ' workflows/start-pull-request-build/pull-request-build-v1.sh'
15+
16+ jobs :
17+ aws-sdk-pr-build :
18+ if : github.event.review.state == 'approved'
19+ runs-on : ubuntu-latest
20+ permissions :
21+ id-token : write
22+ issues : write
23+ pull-requests : write
24+ contents : read
25+ steps :
26+ - name : Configure AWS Credentials
27+ uses : aws-actions/configure-aws-credentials@v4
28+ with :
29+ role-to-assume : ${{ env.IAM_ROLE_ARN }}
30+ role-session-name : PullRequestBuildGitHubAction
31+ aws-region : us-west-2
32+ - name : Download Build Script
33+ run : |
34+ aws s3 cp s3://aws-sdk-builds-github-assets-prod-us-west-2/$SCRIPT_LOCATION ./$DOWNLOAD_FOLDER/$SCRIPT_LOCATION --no-progress
35+ chmod +x ./$DOWNLOAD_FOLDER/$SCRIPT_LOCATION
36+ - name : Build
37+ env :
38+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
39+ run : |
40+ ./$DOWNLOAD_FOLDER/$SCRIPT_LOCATION \
41+ --repo "${{ github.repository }}" \
42+ --branch "${{ github.event.pull_request.head.ref }}" \
43+ --pr-number "${{ github.event.pull_request.number }}" \
44+ --run-id "${{ github.run_id }}"
45+ timeout-minutes : 510 # 8.5 hours
You can’t perform that action at this time.
0 commit comments