Skip to content

Commit

Permalink
auth before push (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominion5254 authored Jan 17, 2025
1 parent a710792 commit eb35b54
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/ghcr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,9 @@ jobs:
env:
IMAGE_ID: ${{ env.IMAGE_ID }}
VERSION: ${{ env.VERSION }}
- name: Build image
run: docker buildx build . --platform linux/amd64,linux/arm64 --tag $IMAGE_ID --label "runnumber=${GITHUB_RUN_ID}" --push
- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
- name: Push image
run: docker push $IMAGE_ID:$VERSION
- name: Build and push image
run: docker buildx build . --platform linux/amd64,linux/arm64 --tag $IMAGE_ID --label "runnumber=${GITHUB_RUN_ID}" --push
- name: Clean up Docker images
run: docker image prune -f

0 comments on commit eb35b54

Please sign in to comment.