We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3594f51 commit 302cf16Copy full SHA for 302cf16
.github/workflows/build.yaml
@@ -38,7 +38,7 @@ jobs:
38
- name: Run Trivy vulnerability scanner
39
uses: aquasecurity/trivy-action@master
40
with:
41
- image-ref: '${{ env.IMAGE_NAME }}:${{ github.sha }}'
+ image-ref: '${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }}'
42
format: 'template'
43
template: '@/contrib/sarif.tpl'
44
output: 'trivy-results.sarif'
@@ -49,6 +49,7 @@ jobs:
49
sarif_file: 'trivy-results.sarif'
50
51
- name: Login to Docker Hub
52
+ if: github.ref == 'refs/heads/master' && github.event_name == 'push'
53
uses: docker/login-action@v1
54
55
username: ${{ secrets.DOCKERHUB_USERNAME }}
0 commit comments