-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #335 from helxplatform/trivy-scan-sapbert
bump versions
- Loading branch information
Showing
19 changed files
with
186 additions
and
94 deletions.
There are no files selected for viewing
This file contains 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 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 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 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,67 @@ | ||
|
||
name: trivy-pr-scan | ||
on: | ||
pull_request: | ||
branches: | ||
- develop | ||
- master | ||
- main | ||
types: [ opened, synchronize ] | ||
paths-ignore: | ||
- README.md | ||
- .old_cicd/* | ||
- .github/* | ||
- .github/workflows/* | ||
- LICENSE | ||
- .gitignore | ||
- .dockerignore | ||
- .githooks | ||
|
||
jobs: | ||
trivy-pr-scan: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
with: | ||
driver-opts: | | ||
network=host | ||
- name: Login to DockerHub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
logout: true | ||
|
||
# Notes on Cache: | ||
# https://docs.docker.com/build/ci/github-actions/examples/#inline-cache | ||
- name: Build Container | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
push: false | ||
load: true | ||
tags: ${{ github.repository }}:vuln-test | ||
cache-from: type=registry,ref=${{ github.repository }}:buildcache | ||
cache-to: type=registry,ref=${{ github.repository }}:buildcache,mode=max | ||
|
||
# We will not be concerned with Medium and Low vulnerabilities | ||
- name: Run Trivy vulnerability scanner | ||
uses: aquasecurity/trivy-action@master | ||
with: | ||
image-ref: '${{ github.repository }}:vuln-test' | ||
format: 'sarif' | ||
severity: 'CRITICAL,HIGH' | ||
output: 'trivy-results.sarif' | ||
exit-code: '1' | ||
# Scan results should be viewable in GitHub Security Dashboard | ||
# We still fail the job if results are found, so below will always run | ||
# unless manually canceled. | ||
- name: Upload Trivy scan results to GitHub Security tab | ||
uses: github/codeql-action/upload-sarif@v2 | ||
if: '!cancelled()' | ||
with: | ||
sarif_file: 'trivy-results.sarif' |
This file contains 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 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 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 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 |
---|---|---|
@@ -1,29 +1,29 @@ | ||
aiohttp | ||
asyncio | ||
fastapi==0.95.0 | ||
uvicorn==0.23.2 | ||
fastapi | ||
uvicorn | ||
elasticsearch[async]==8.5.2 | ||
gunicorn | ||
itsdangerous | ||
Jinja2 | ||
jsonschema | ||
MarkupSafe | ||
ormar==0.12.1 | ||
mistune==2.0.3 | ||
pluggy==1.0.0 | ||
pyrsistent==0.17.3 | ||
ormar | ||
mistune | ||
pluggy | ||
pyrsistent | ||
pytest | ||
pytz==2021.1 | ||
PyYAML==6.0 | ||
requests==2.31.0 | ||
# old redis==4.4.2 | ||
redis==4.5.4 | ||
requests-cache==0.9.8 | ||
six==1.16.0 | ||
pytz | ||
PyYAML | ||
requests | ||
redis | ||
requests-cache | ||
six | ||
|
||
# Click for command line arguments | ||
# We use Click 7.0 because that's what one of the pinned packages above use. | ||
click | ||
httpx>=0.24.1 | ||
httpx | ||
linkml-runtime==1.6.0 | ||
bmt==1.1.0 | ||
urllib3>=1.26.17 | ||
urllib3 |
Oops, something went wrong.