Skip to content

Commit 96fb7ed

Browse files
committed
change: enable github actions for PRs
1 parent 7fecc33 commit 96fb7ed

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

.github/workflows/codebuild-ci.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: PR Checks
2+
on:
3+
pull_request:
4+
5+
concurrency:
6+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
7+
cancel-in-progress: true
8+
9+
permissions:
10+
id-token: write # This is required for requesting the JWT
11+
12+
jobs:
13+
codestyle-doc-tests:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Configure AWS Credentials
17+
uses: aws-actions/configure-aws-credentials@v4
18+
with:
19+
role-to-assume: ${{ secrets.CI_AWS_ROLE_ARN }}
20+
aws-region: us-west-2
21+
role-duration-seconds: 10800
22+
- name: Run Codestyle & Doc Tests
23+
uses: aws-actions/aws-codebuild-run-build@v1
24+
with:
25+
project-name: sagemaker-python-sdk-ci-codestyle-doc-tests
26+
unit-tests:
27+
runs-on: ubuntu-latest
28+
strategy:
29+
fail-fast: false
30+
matrix:
31+
python-version: ["py38", "py39", "py310"]
32+
steps:
33+
- name: Configure AWS Credentials
34+
uses: aws-actions/configure-aws-credentials@v4
35+
with:
36+
role-to-assume: ${{ secrets.CI_AWS_ROLE_ARN }}
37+
aws-region: us-west-2
38+
role-duration-seconds: 10800
39+
- name: Run Unit Tests
40+
uses: aws-actions/aws-codebuild-run-build@v1
41+
with:
42+
project-name: sagemaker-python-sdk-ci-unit-tests
43+
env-vars-for-codebuild: |
44+
PY_VERSION
45+
env:
46+
PY_VERSION: ${{ matrix.python-version }}

0 commit comments

Comments
 (0)