add(action): add check if sbom input is empty #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test action | |
on: | |
push: | |
branches: | |
- main | |
env: | |
IMAGE: ttl.sh/attest-sign | |
jobs: | |
test: | |
name: Build container and push to ttl.sh | |
runs-on: ubuntu-20.04 | |
permissions: | |
contents: "read" | |
id-token: "write" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Docker meta | |
id: meta | |
uses: docker/metadata-action@v5 | |
with: | |
images: ${{ env.IMAGE }} | |
tags: 2 | |
- uses: docker/build-push-action@v5 | |
id: build_push | |
with: | |
context: test | |
# The tag indicates 2 min ttl | |
tags: ${{ steps.meta.outputs.tags }} | |
push: true | |
- name: "Attest and sign test image" | |
uses: './' | |
with: | |
image_ref: ${{ env.IMAGE }}@${{ steps.build_push.outputs.digest }} |