-
Notifications
You must be signed in to change notification settings - Fork 89
Parallelize CI Jobs #263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Parallelize CI Jobs #263
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
5ca0d1d
First pass at parallelized tests
PSalant726 2cfff1f
Rename workflow file, polish job and step names
PSalant726 b8e5ef8
Use the PR's HEAD commit sha
PSalant726 39b13eb
Start fidesctl before running the test suite
PSalant726 9b01d03
Remove postgres where it isn't needed
PSalant726 252d805
Try renaming postgres image to fidesctl-db
PSalant726 eca41f3
update the docker-compose to add an image tag, update the CI checks i…
f609a81
fix the image name, add caching to docker-compose
6f6a12e
restore the makefile CI checks and hope that compose-file caching wor…
03d2899
try to fix the docker-compose caching
3588500
tests indicated that a compose-build step has to run before caching i…
714598c
change docker-compose to docker compose, add a logger in the CI checks
ce440cc
move the debugger line
24f90d2
enable buildkit explicitly
7c34d1f
add another flag to try
368b890
try adding the load flag
03a389e
remove the build step from docker-compose, it expects the ethyca/fide…
6a4b3eb
Merge branch 'main' into ps/parallelize-ci
6aafbad
remove the build step from the individual makefile commands
77bd46d
added a docker build step to the pre-commit checks
98169e7
make suggested changes
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,158 @@ | ||
| name: PR Checks | ||
|
|
||
| on: | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| paths: | ||
| - fidesctl/** | ||
| - .github/workflows/pr_checks.yaml | ||
|
|
||
| env: | ||
| CONTAINER: fidesctl-local | ||
| IMAGE: ethyca/fidesctl:local | ||
|
|
||
| jobs: | ||
| Build: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Set up Docker Buildx | ||
| id: buildx | ||
| uses: docker/setup-buildx-action@v1 | ||
|
|
||
| - name: Build fidesctl container | ||
| uses: docker/build-push-action@v2 | ||
| with: | ||
| builder: ${{ steps.buildx.outputs.name }} | ||
| context: ./fidesctl | ||
| file: ./fidesctl/Dockerfile | ||
| outputs: type=docker,dest=/tmp/${{ env.CONTAINER }}.tar | ||
| push: false | ||
| tags: ${{ env.IMAGE }} | ||
|
|
||
| - name: Upload fidesctl container | ||
| uses: actions/upload-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/${{ env.CONTAINER }}.tar | ||
| retention-days: 1 | ||
|
|
||
| Fidesctl: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
ThomasLaPiana marked this conversation as resolved.
|
||
|
|
||
| - name: Check fidesctl installation | ||
| run: make check-install | ||
|
|
||
| - name: Run fidesctl evaluation | ||
| run: make fidesctl | ||
|
|
||
| Black: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Run formatter | ||
| run: make black | ||
|
|
||
| Pylint: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Run linter | ||
| run: make pylint | ||
|
|
||
| Mypy: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Run typechecker | ||
| run: make mypy | ||
|
|
||
| Xenon: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Run cyclomatic complexity check | ||
| run: make xenon | ||
|
|
||
| Test: | ||
| needs: Build | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Download fidesctl container | ||
| uses: actions/download-artifact@v2 | ||
| with: | ||
| name: ${{ env.CONTAINER }} | ||
| path: /tmp/ | ||
|
|
||
| - name: Load fidesctl image | ||
| run: docker load --input /tmp/${{ env.CONTAINER }}.tar | ||
|
|
||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Run test suite | ||
| run: make pytest | ||
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.