-
Notifications
You must be signed in to change notification settings - Fork 653
Open
Description
Description
I'm trying to setup a shared cache using cache-from and cache-to on a repo.
The docker doc says that we can use multiple caches.
But with the plugin I did not found a way to declare more that one cacheFrom for buildx.
Is it possible to do so ?
<!-- [...] redacted -->
<buildx>
<platforms>
<platform>${docker.platforms}</platform>
</platforms>
<cacheTo>type=registry,ref=${docker.cache.registry}/my-image:${git.branch}</cacheTo>
<cacheFrom>type=registry,ref=${docker.cache.registry}/my-image:${git.branch}</cacheFrom>
<!-- the last cacheFrom overrides the first definition -->
<cacheFrom>type=registry,ref=${docker.cache.registry}/my-image:master</cacheFrom>
</buildx>
<!-- [...] redacted -->Similarly to docker.cacheFrom.idx I also tried declaring a property list docker.buildx.cacheFrom.idx:
<buildx>
<platforms>
<platform>${docker.platforms}</platform>
</platforms>
<cacheTo>type=registry,ref=${docker.cache.registry}/my-image:${git.branch}</cacheTo>
<!-- Prop list does not work for buildx cachefrom
Unable to parse configuration of mojo io.fabric8:docker-maven-plugin:0.45.0:build for parameter cacheFrom.1: Cannot find 'cacheFrom.1' in class io.fabric8.maven.docker.config.BuildXConfiguration -->
<cacheFrom.1>type=registry,ref=${docker.cache.registry}/my-image:${git.branch}</cacheFrom.1>
<cacheFrom.2>type=registry,ref=${docker.cache.registry}/my-image:master</cacheFrom.2>
</buildx>remiville
Metadata
Metadata
Assignees
Labels
No labels