From 5f607e733a0cf0735cba71e91709a860538010d5 Mon Sep 17 00:00:00 2001 From: Danilo Hoffmann Date: Wed, 13 Sep 2023 10:06:21 +0000 Subject: [PATCH] Fix: propagate --cache-from to buildx build --- src/spec-node/containerFeatures.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/spec-node/containerFeatures.ts b/src/spec-node/containerFeatures.ts index 21649f10a..dc750b045 100644 --- a/src/spec-node/containerFeatures.ts +++ b/src/spec-node/containerFeatures.ts @@ -85,6 +85,9 @@ export async function extendImage(params: DockerResolverParameters, config: Subs if (params.buildxCacheTo) { args.push('--cache-to', params.buildxCacheTo); } + if (!params.buildNoCache) { + params.additionalCacheFroms.forEach(cacheFrom => args.push('--cache-from', cacheFrom)); + } for (const buildContext in featureBuildInfo.buildKitContexts) { args.push('--build-context', `${buildContext}=${featureBuildInfo.buildKitContexts[buildContext]}`);