fix(images): minimize ql3 runtime base

This commit is contained in:
whyour
2026-08-22 12:44:49 +08:00
parent ca8ddf34b8
commit f1cca9a3ed
13 changed files with 119 additions and 40 deletions
@@ -1,6 +1,6 @@
# QingLong 3.0 镜像 OS 漏洞门
本流程覆盖 `control|admin|local × amd64|arm64` 个 release candidate 的 Debian/base image package,不替代 npm
本流程覆盖 `control|control-ai|admin|local|worker × amd64|arm64` 个 release candidate 的 OS/base image package,不替代 npm
production dependency audit、CycloneDX、BuildKit SBOM/provenance、Cosign 或 GitHub attestation。
## 日常检查
@@ -17,7 +17,7 @@ pnpm audit:cluster-deployment:ql3
{"schemaVersion":1,"fixture":"qinglong/image-os-vulnerability-exceptions@v1","compatible":true,"exceptionCount":0,"imageExceptionCounts":{"admin":0,"control":0,"local":0}}
```
真实 scan 在 QL3 CI 已有个 native build 后执行;受保护 release 的个 native job 各自只构建一次 OCI layout tar
真实 scan 在 QL3 CI 已有个 native build 后执行;受保护 release 的个 native job 各自只构建一次 OCI layout tar
Trivy 直接扫描该 tar。扫描成功后才解包、审计并上传同一 OCI graphpublisher 只合并 amd64/arm64 graph,不再 build。
只有六份 artifact 和 D-236 私密 evidence job 全部成功,publisher 才会启动。scanner/DB 网络故障与漏洞命中使用相同
的失败关闭结果,但日志会区分下载错误和 finding。
@@ -80,8 +80,8 @@ pnpm audit:image-release:ql3
1. 阅读 Trivy 官方 release 与 security advisory,确认目标版本不在已知暴露窗口;
2. 解析 signed/immutable action release 到完整 commit SHA,审查 composite action 的所有 nested action pin
3. 固定 scanner exact version,禁止 `latest`;保持 cache false、OS-only、unfixed 不忽略;
4. 对 Node base 的多架构 manifest digest 执行签名/来源核验;个 production Dockerfile 必须同步更新 exact digest
5. 更新 ADR、静态审计 expectation 与 mutation tests;执行个 native scan 后才能发布;
4. 对 Node base 的多架构 manifest digest 执行签名/来源核验;个 production Dockerfile 的 runtime stage 必须同步更新 exact digest
5. 更新 ADR、静态审计 expectation 与 mutation tests;执行个 native scan 后才能发布;
6. 修复后删除已不需要的 exceptions,不等待 `expiresOn`
## 失败恢复