|
1 | 1 | name: Aqua
|
| 2 | + |
2 | 3 | on:
|
3 | 4 | pull_request:
|
4 | 5 | branches:
|
5 | 6 | - main
|
| 7 | + - develop |
6 | 8 |
|
7 | 9 | jobs:
|
8 | 10 | aqua:
|
9 |
| - name: Aqua scanner |
10 |
| - runs-on: ubuntu-22.04 |
| 11 | + name: Code scanning |
| 12 | + runs-on: ubuntu-24.04 |
| 13 | + |
| 14 | + permissions: |
| 15 | + contents: read |
| 16 | + id-token: write |
| 17 | + |
11 | 18 | steps:
|
12 | 19 | - name: Checkout code
|
13 | 20 | uses: actions/checkout@v4
|
| 21 | + with: |
| 22 | + show-progress: false |
| 23 | + |
| 24 | + - name: Authenticate to Google Cloud |
| 25 | + id: gcloud-auth |
| 26 | + uses: google-github-actions/auth@v2 |
| 27 | + with: |
| 28 | + token_format: access_token |
| 29 | + workload_identity_provider: projects/699052769907/locations/global/workloadIdentityPools/github-identity-pool-shared/providers/github-identity-provider-shared # yamllint disable-line |
| 30 | + service_account: github-gar-almasyliuspaymentpl@lyrical-carver-335213.iam.gserviceaccount.com |
| 31 | + |
| 32 | + - name: Authenticate to Artifact Registry |
| 33 | + uses: docker/login-action@v3 |
| 34 | + with: |
| 35 | + registry: europe-docker.pkg.dev |
| 36 | + username: oauth2accesstoken |
| 37 | + password: ${{ steps.gcloud-auth.outputs.access_token }} |
14 | 38 |
|
15 | 39 | - name: Run Aqua scanner
|
16 | 40 | uses: docker://aquasec/aqua-scanner
|
17 |
| - with: |
18 |
| - args: trivy fs --sast --reachability --scanners misconfig,vuln,secret . |
19 |
| - # To customize which severities add the following flag: --severity UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL |
20 |
| - # To enable SAST scanning, add: --sast |
21 |
| - # To enable reachability scanning, add: --reachability |
22 |
| - # To enable npm/dotnet non-lock file scanning, add: --package-json / --dotnet-proj |
23 | 41 | env:
|
24 | 42 | AQUA_KEY: ${{ secrets.AQUA_KEY }}
|
25 | 43 | AQUA_SECRET: ${{ secrets.AQUA_SECRET }}
|
26 | 44 | GITHUB_TOKEN: ${{ github.token }}
|
27 | 45 | AQUA_URL: https://api.eu-1.supply-chain.cloud.aquasec.com
|
28 | 46 | CSPM_URL: https://eu-1.api.cloudsploit.com
|
29 |
| - TRIVY_RUN_AS_PLUGIN: "aqua" |
30 |
| - # For http/https proxy configuration add env vars: HTTP_PROXY/HTTPS_PROXY, CA-CRET (path to CA certificate) |
| 47 | + TRIVY_RUN_AS_PLUGIN: aqua |
| 48 | + TRIVY_DB_REPOSITORY: europe-docker.pkg.dev/lyrical-carver-335213/ghcr-remote-cache/aquasecurity/trivy-db:2 |
| 49 | + with: |
| 50 | + args: trivy fs --sast --reachability --scanners misconfig,vuln,secret . |
0 commit comments