Repository navigation
Can the default docker driver be used with remote cache? #2165
Replies: 1 comment
|
With Buildx v0.10.4, the default docker driver cannot use the registry cache exporter/importer in the same way as the docker-container driver. That is the limitation you are observing, not a cache-reference syntax problem. Use one of these paths:
Also note that --cache-from imports an existing cache but does not update it. Add the matching --cache-to on the build that should populate/refesh the registry cache. The current Buildx docs list cache-from/cache-to as external cache sources/destinations, but driver support depends on the backing BuildKit/image-store configuration: Build cache options. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
I have a use case where I need to load an image locally, but I'd also like to take advantage of pulling cache from a remote registry. I've noticed that using the docker-container driver is somewhat slow when it comes to loading an image locally after a build whereas hitting the default docker driver is way faster.
However, I noticed that using the default driver + trying to pull remote cache doesn't seem to work? Using the same build configurations, I was not observing the default driver builds actually attempting to pull remote cache despite pulling the manifest.
Sample command:
Where before running the above, a docker builder instance is pointed at that uses the docker-container driver (allowing for remote cache to be utilized) or the default driver is pointed at (which appears to not utilize the remote cache).
The buildx version I have available to me is github.com/docker/buildx v0.10.4 c513d34, perhaps this feature is in a newer version?
All reactions