From c132fd423ad7dd43ae1db246caa5dd973802d316 Mon Sep 17 00:00:00 2001 From: OG T Date: Fri, 10 Apr 2026 00:23:54 +0800 Subject: [PATCH] =?UTF-8?q?fix(drift):=20COPY=20k8s/=20=E9=80=B2=20API=20i?= =?UTF-8?q?mage=20=E2=80=94=20drift=5Fdetector=20Git=20state=20=E6=AF=94?= =?UTF-8?q?=E5=B0=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit drift_detector 的 GitStateReader 需要讀 k8s/*.yaml 來比對 K8s 實際狀態, 但 API Pod 沒有此目錄導致 k8s_dir_not_found,掃描結果永遠為空。 Co-Authored-By: Claude Sonnet 4.6 --- apps/api/Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apps/api/Dockerfile b/apps/api/Dockerfile index 220b66a4..da9a44c6 100644 --- a/apps/api/Dockerfile +++ b/apps/api/Dockerfile @@ -55,6 +55,8 @@ COPY apps/api/src/ ./src/ COPY apps/api/models.json ./models.json # 2026-04-09 ogt: 規則引擎配置 — alert_rule_engine.py 從此檔載入規則 COPY apps/api/alert_rules.yaml ./alert_rules.yaml +# 2026-04-10 Claude Sonnet 4.6: drift_detector 需要 k8s/ YAML 做 Git state 比對 +COPY k8s/ ./k8s/ # Install openssh-client — SSH_COMMAND Playbook 執行路徑需要 ssh binary # (2026-04-09 Claude Sonnet 4.6 Asia/Taipei, Bug #6 修正 — python:3.11-slim 無 openssh-client)