From ab8f0e472d18623e842cf7b1517639ba4d6282f8 Mon Sep 17 00:00:00 2001 From: Graham McIntire Date: Fri, 13 Feb 2026 17:41:55 -0600 Subject: [PATCH] fix: use registry cache with mode=max for full build stage caching Replace inline cache with dedicated buildcache tag that stores all intermediate builder layers. Unchanged stages like deps and compile will be pulled from cache instead of rebuilt. --- .forgejo/workflows/build-deploy.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.forgejo/workflows/build-deploy.yml b/.forgejo/workflows/build-deploy.yml index e5b1f789..ea22a9ba 100644 --- a/.forgejo/workflows/build-deploy.yml +++ b/.forgejo/workflows/build-deploy.yml @@ -36,6 +36,7 @@ jobs: echo "image=${{ secrets.REGISTRY_URL }}/${{ github.repository }}" >> $GITHUB_OUTPUT echo "sha_tag=${{ secrets.REGISTRY_URL }}/${{ github.repository }}:${{ github.sha }}" >> $GITHUB_OUTPUT echo "latest_tag=${{ secrets.REGISTRY_URL }}/${{ github.repository }}:latest" >> $GITHUB_OUTPUT + echo "cache_tag=${{ secrets.REGISTRY_URL }}/${{ github.repository }}:buildcache" >> $GITHUB_OUTPUT - name: Build and push Docker image uses: docker/build-push-action@v6 @@ -46,10 +47,8 @@ jobs: tags: | ${{ steps.meta.outputs.sha_tag }} ${{ steps.meta.outputs.latest_tag }} - cache-from: type=registry,ref=${{ steps.meta.outputs.latest_tag }} - cache-to: type=inline - build-args: | - BUILDKIT_INLINE_CACHE=1 + cache-from: type=registry,ref=${{ steps.meta.outputs.cache_tag }} + cache-to: type=registry,ref=${{ steps.meta.outputs.cache_tag }},mode=max deploy: runs-on: ubuntu-latest