From c9375c3b077fbefe05428f977371c6eb489a2ee3 Mon Sep 17 00:00:00 2001 From: Andrew Dryga Date: Tue, 31 Oct 2023 15:16:48 -0600 Subject: [PATCH] Use max mode for docker layer caching --- .github/workflows/cd.yml | 2 +- .github/workflows/ci.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index b2d754465..3371cb5a3 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -206,7 +206,7 @@ jobs: cache-from: | type=registry,ref=${{ steps.login.outputs.registry }}/cache/${{ matrix.name.artifact }}:main cache-to: | - type=registry,ref=${{ steps.login.outputs.registry }}/cache/${{ matrix.name.artifact }}:main + type=registry,ref=${{ steps.login.outputs.registry }}/cache/${{ matrix.name.artifact }}:main,mode=max target: release outputs: type=image,name=${{ steps.login.outputs.registry }}/firezone/${{ matrix.name.artifact}},push-by-digest=true,name-canonical=true,push=true - name: Export digest diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 719223d6a..98730c78c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -107,7 +107,7 @@ jobs: # This will write the cache on main even if integration tests fail, # but it'll just be corrected on the next successful build. cache-to: | - type=registry,ref=${{steps.login.outputs.registry}}/cache/${{ matrix.image_name}}:${{ env.CACHE_TAG }} + type=registry,ref=${{steps.login.outputs.registry}}/cache/${{ matrix.image_name}}:${{ env.CACHE_TAG }},mode=max file: ${{ matrix.context }}/Dockerfile push: true target: ${{ matrix.target }}