From 666a1c29f9eff2bf4f0741b89f0798dd01de9f5b Mon Sep 17 00:00:00 2001 From: "cnb.dQC5J6ohAGA" <8m0v8c12sZDrY2infddElF+cnb.dQC5J6ohAGA@noreply.cnb.cool> Date: Thu, 17 Sep 2026 09:53:29 +0800 Subject: [PATCH] fix(ci): list plugin.sh in build.by so the image build can find it CNB only puts the files named in `build.by` into the build context of a `docker.build` environment image, and silently omits everything else rather than failing. The kaniko image's `COPY .ci/kaniko/plugin.sh` was therefore reading from an empty "client dir", which is why the build failed with `"/.ci/kaniko/plugin.sh": not found` while the file is very much in the repository. The Dockerfile itself is exempt from the filter, so `dockerfile:` alone had looked sufficient. Ref: #16 --- .cnb.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.cnb.yml b/.cnb.yml index 0a64431..fe4b2f1 100644 --- a/.cnb.yml +++ b/.cnb.yml @@ -112,6 +112,10 @@ main: docker: build: dockerfile: .ci/kaniko/Dockerfile + # CNB 只把 `by` 里列出的文件放进构建上下文,`plugin.sh` 不在列的话 + # 并不会报错,只是 Dockerfile 里那句 COPY 找不到文件。 + by: + - .ci/kaniko/plugin.sh stages: - name: login script: |