Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/actions/docker-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,8 @@ runs:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
cache-from: type=gha
cache-to: ${{ case(inputs.publish == 'true', format('type=registry,ref={0}', steps.meta.outputs.tags), 'type=gha,mode=max') }}
cache-from: |
type=gha
type=registry,ref=ghcr.io/${{ github.repository }}:buildcache

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the change should resolve the issue. The only thing I'm unsure of is why we use the registry cache in the first place instead of just using gha. The docs don't explain the difference other than gha is still in beta.

cache-to: ${{ case(inputs.publish == 'true', format('type=registry,ref=ghcr.io/{0}:buildcache,mode=max', github.repository), 'type=gha,mode=max') }}
platforms: linux/amd64
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v6

- name: Test Docker build
- name: Publish Docker build
uses: ./.github/actions/docker-build
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
Loading