[CI/Build][CPU] Shrink triton-cpu-build layer by dropping build artifacts (#52127)

Signed-off-by: jiang1.li <jiang1.li@intel.com>

Li, Jiang committed Aug 13, 2026 at 17:17 UTC 1c3633acafd6bbde1f3636cee9799e3ab0879d13
1 file changed +3
docker/Dockerfile.cpu
+3
@@ -259,6 +259,7 @@ RUN mkdir dist
259 RUN --mount=type=cache,target=/root/.cache/uv \
260 --mount=type=cache,target=/root/.cache/ccache \
261 --mount=type=cache,target=/vllm-workspace/.deps,sharing=locked \
262 + --mount=type=cache,target=/root/.triton \
263 --mount=type=secret,id=aws-credentials,target=/root/.aws/credentials,required=false \
264 if [ "$TARGETARCH" = "amd64" ] || [ "$VLLM_CPU_X86" != "0" ]; then \
265 git clone --recurse-submodules --shallow-submodules --filter=blob:none "https://github.com/triton-lang/triton-cpu.git"; \
@@ -271,6 +272,8 @@ RUN --mount=type=cache,target=/root/.cache/uv \
272 fi; \
273 uv build --wheel --out-dir=../dist; \
274 if [ "$USE_SCCACHE" = "1" ]; then sccache --show-stats; fi; \
275 + cd ..; \
276 + rm -rf triton-cpu; \
277 fi
278
279 ######################### TEST DEPS #########################