Skip to content

Commit

Permalink
test docker
Browse files Browse the repository at this point in the history
  • Loading branch information
ejahnGithub committed May 2, 2024
1 parent e72e1df commit 9ba0b3f
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/build-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,18 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Build Docker image
run: docker build . -t ${{ secrets.DOCKER_IMAGE }}

- name: Push Docker image
run: docker push ${{ secrets.DOCKER_IMAGE }}
- name: Docker build and push
id: docker_build
uses: docker/build-push-action@v2
with:
context: .
file: Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }}

- name: Generate artifact attestation
uses: actions/attest-build-provenance@v1
with:
subject-name: ${{ secrets.DOCKER_IMAGE }}
subject-digest: ${{ secrets.DOCKER_IMAGE_DIGEST }}
subject-name: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
subject-digest: ${{ steps.docker_build.outputs.digest }}
push-to-registry: true

0 comments on commit 9ba0b3f

Please sign in to comment.