Skip to content

Commit

Permalink
👷 Merge docker build + push step
Browse files Browse the repository at this point in the history
  • Loading branch information
Yannig committed Nov 17, 2023
1 parent c11c47e commit d2e65d1
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Set releasw version
- name: Set release version
id: version
run: echo "version=${{ needs.build.outputs.version }}" >> $GITHUB_OUTPUT

Expand Down Expand Up @@ -173,6 +173,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ${{ env.REGISTRY }} -u $ --password-stdin

- name: Build image
id: docker-meta
env:
Expand All @@ -182,14 +185,6 @@ jobs:
TAG_SUFFIX=$(echo "-${{ matrix.name }}" | sed s/-ubuntu//)
echo "image-id=$IMAGE_NAME" >> $GITHUB_OUTPUT
echo "image-version=${VERSION}${TAG_SUFFIX}" >> $GITHUB_OUTPUT
- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ${{ env.REGISTRY }} -u $ --password-stdin

- name: Push image
env:
VERSION: "${{ needs.release.outputs.version }}"
run: |
make push-${{ matrix.name }}-image
- name: Setup cosign
Expand All @@ -210,7 +205,7 @@ jobs:
run: make sign-${{ matrix.name }}-image

- name: Container scan
uses: aquasecurity/trivy-action@0.8.0
uses: aquasecurity/trivy-action@0.14.0
env:
image-ref: "${{ steps.docker-meta.outputs.image-id }}:${{ steps.docker-meta.outputs.image-version }}"
with:
Expand Down

0 comments on commit d2e65d1

Please sign in to comment.