mirror of
https://github.com/docker/build-push-action.git
synced 2025-04-01 20:50:09 +02:00
Set mode=max to cache intermediate stages
buildx caches layer only in the final stage by default. To speedup multi-stage Dockerfile build, better to set `mode=max`: https://docs.docker.com/engine/reference/commandline/buildx_build/#cache-to Signed-off-by: saiya <saiya.v6@gmail.com>
This commit is contained in:
parent
ad44023a93
commit
c9bcbf71e2
1 changed files with 2 additions and 2 deletions
|
@ -41,7 +41,7 @@ jobs:
|
|||
push: true
|
||||
tags: user/app:latest
|
||||
cache-from: type=registry,ref=user/app:latest
|
||||
cache-to: type=inline
|
||||
cache-to: type=inline,mode=max
|
||||
```
|
||||
|
||||
## GitHub cache
|
||||
|
@ -95,7 +95,7 @@ jobs:
|
|||
push: true
|
||||
tags: user/app:latest
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max
|
||||
-
|
||||
# Temp fix
|
||||
# https://github.com/docker/build-push-action/issues/252
|
||||
|
|
Loading…
Add table
Reference in a new issue