From a36646349650b14184e35485a9125b6e40b329e6 Mon Sep 17 00:00:00 2001 From: Ludy Date: Wed, 14 Jan 2026 01:36:41 +0100 Subject: [PATCH] ci(build): scope Docker layer cache per artifact to avoid cross-contamination (#5453) This pull request updates the Docker build caching strategy in the GitHub Actions workflow to improve cache isolation and efficiency. The main change is the introduction of a cache `scope` based on the `artifact-suffix` matrix value. **Build caching improvements:** * [`.github/workflows/build.yml`](diffhunk://#diff-5c3fa597431eda03ac3339ae6bf7f05e1a50d6fc7333679ec38e21b337cb6721L329-R330): Updated `cache-from` and `cache-to` in the Docker build step to use a scoped cache (`scope=${{ matrix.artifact-suffix }}`), enabling better cache isolation across different build variants. --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index da110b781..8755d41ac 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -326,8 +326,8 @@ jobs: context: . file: ./${{ matrix.docker-rev }} push: false - cache-from: type=gha - cache-to: type=gha,mode=max + cache-from: type=gha,scope=${{ matrix.artifact-suffix }} + cache-to: type=gha,mode=max,scope=${{ matrix.artifact-suffix }} platforms: linux/amd64,linux/arm64/v8 provenance: true sbom: true