Skip to content

Commit

Permalink
Add mode=max when exporting cache
Browse files Browse the repository at this point in the history
  • Loading branch information
doganulus committed Jul 20, 2024
1 parent 7c6e0a6 commit e5b2f1f
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions .github/workflows/builder-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,8 @@ jobs:
tags: |
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
load: true
# no-cache: true
cache-from: |
type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
cache-to: type=inline
no-cache: true
cache-to: type=inline,mode=max

- name: Build builder w/cache image
uses: docker/build-push-action@v6
Expand All @@ -81,7 +79,7 @@ jobs:
cache-from: |
type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder-with-cache
cache-to: type=inline
cache-to: type=inline,mode=max

- name: Push builder image
uses: docker/build-push-action@v6
Expand All @@ -95,7 +93,7 @@ jobs:
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
push: true
cache-from: type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
cache-to: type=inline
cache-to: type=inline,mode=max

- name: Push builder-with-cache image
uses: docker/build-push-action@v6
Expand All @@ -111,4 +109,4 @@ jobs:
cache-from: |
type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder
type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.AUTOWARE_VERSION }}-builder-with-cache
cache-to: type=inline
cache-to: type=inline,mode=max

0 comments on commit e5b2f1f

Please sign in to comment.