Skip to content

Commit

Permalink
Update Context to path based
Browse files Browse the repository at this point in the history
  • Loading branch information
BronzBierd committed Dec 20, 2024
1 parent a6966ad commit aa61a48
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion .github/workflows/ci-trivy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ jobs:
context: ["docker/web", "docker/api"]
include:
- context: docker/web
context_path: .
image_name: scv-web
sarif_file: trivy-web.sarif
docker_file: docker/web/Dockerfile.release
Expand All @@ -27,13 +28,22 @@ jobs:
VUE_ON_NGINX_SRC=../../docker/vue-on-nginx
WEB_SRC=../../web
- context: docker/api
context_path: .
image_name: scv-api
sarif_file: trivy-api.sarif
docker_file: docker/api/Dockerfile.release
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Cache Docker layers
uses: actions/cache@v4
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Setup
uses: docker/setup-buildx-action@v3
with:
Expand All @@ -42,7 +52,7 @@ jobs:
- name: Build
uses: docker/build-push-action@v6
with:
context: ${{matrix.context}}
context: ${{matrix.context_path}}
file: ${{matrix.docker_file}}
push: false
load: true
Expand Down

0 comments on commit aa61a48

Please sign in to comment.