Skip to content
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

add trivvy and fix vulnerability #77

Merged
merged 10 commits into from
Nov 8, 2024
Merged
27 changes: 27 additions & 0 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Run Trivy vulnerability scanner


on: [ push ]

jobs:
main:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Build wis2box-api
run: |
docker build -t wis2box-api:test .
- name: Run Trivy vulnerability scanner on wis2box-api
if: always()
uses: aquasecurity/trivy-action@0.20.0
env:
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db:2
TRIVY_JAVA_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-java-db:1
with:
image-ref: 'wis2box-api:test'
format: 'table'
exit-code: '1'
ignore-unfixed: true
vuln-type: 'os,library'
severity: 'CRITICAL,HIGH'
5 changes: 2 additions & 3 deletions .github/workflows/wis2box_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,8 @@ jobs:
working-directory: docker_compose_test
run: |
docker exec -t wis2box-api-test-wis2box-management wis2box metadata station publish-collection -p /data/wis2box/metadata/station/station_list.csv -th origin/a/wis2/synop-test/data/core/weather/surface-based-observations/synop
docker exec -t wis2box-api-test-wis2box-management wis2box metadata station publish-collection -p /data/wis2box/metadata/station/station_list.csv -th origin/a/wis2/csv-test/data/core/weather/surface-based-observations/synop
docker exec -t wis2box-api-test-wis2box-management wis2box metadata station publish-collection -p /data/wis2box/metadata/station/station_list.csv -th origin/a/wis2/bufr-test/data/core/weather/surface-based-observations/synop

docker exec -t wis2box-api-test-wis2box-management wis2box metadata station add-topic --wsi 0-20000-0-15015 origin/a/wis2/csv-test/data/core/weather/surface-based-observations/synop
docker exec -t wis2box-api-test-wis2box-management wis2box metadata station add-topic --wsi 0-20000-0-16344 origin/a/wis2/bufr-test/data/core/weather/surface-based-observations/synop
- name: Check status code API
working-directory: docker_compose_test
run: |
Expand Down
Loading