From ec0a2b9985e8692c336b5d5faa53d7e2dcbc0628 Mon Sep 17 00:00:00 2001 From: Your Name Date: Mon, 29 Jun 2026 11:13:03 +0800 Subject: [PATCH] chore(runner): record non110 ready deploy blocker readback --- .../test_delivery_closure_workbench_api.py | 66 +++++++++---------- docs/LOGBOOK.md | 22 +++++++ ...tion-deploy-readback-blocker.snapshot.json | 14 ++-- 3 files changed, 60 insertions(+), 42 deletions(-) diff --git a/apps/api/tests/test_delivery_closure_workbench_api.py b/apps/api/tests/test_delivery_closure_workbench_api.py index 6614bec8..b44c4a17 100644 --- a/apps/api/tests/test_delivery_closure_workbench_api.py +++ b/apps/api/tests/test_delivery_closure_workbench_api.py @@ -25,7 +25,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): assert data["summary"]["refs_sync_authorized"] is True assert data["summary"]["workflow_trigger_authorized"] is True assert data["summary"]["production_deploy_status"] == ( - "blocked_waiting_authorized_gitea_workflow_dispatch_and_runner_queue" + "blocked_production_image_not_current" ) assert data["summary"]["production_deploy_source_control_main_ready"] is True assert data["summary"]["production_deploy_image_tag_matches_main"] is False @@ -44,7 +44,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): data["summary"]["production_deploy_dispatch_without_token_message"] == "token is required" ) - assert data["summary"]["production_deploy_hard_blocker_count"] == 3 + assert data["summary"]["production_deploy_hard_blocker_count"] == 2 assert data["summary"]["production_deploy_latest_visible_cd_run_id"] == "3853" assert data["summary"]["production_deploy_latest_visible_cd_run_status"] == ( "Waiting" @@ -101,7 +101,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): ) assert ( data["summary"]["production_deploy_non110_runner_cd_closure_status"] - == "blocked_non110_runner_not_ready" + == "blocked_production_image_not_current" ) assert ( data["summary"]["production_deploy_non110_runner_cd_closure_required"] @@ -121,44 +121,42 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): data["summary"][ "production_deploy_non110_runner_cd_closure_ordered_completed_prefix_count" ] - == 0 + == 4 ) assert ( data["summary"][ "production_deploy_non110_runner_cd_closure_evidence_completed_step_count" ] - == 2 + == 4 ) assert ( data["summary"][ "production_deploy_non110_runner_cd_closure_ordered_completion_percent" ] - == 0 + == 67 ) assert ( data["summary"][ "production_deploy_non110_runner_cd_closure_evidence_completion_percent" ] - == 33 + == 67 ) assert ( data["summary"][ "production_deploy_non110_runner_cd_closure_next_blocked_step_index" ] - == 1 + == 5 ) assert ( data["summary"][ "production_deploy_non110_runner_cd_closure_next_blocked_step_id" ] - == "non110_runner_registration_metadata" + == "production_image_tag_current" ) assert data["summary"][ "production_deploy_non110_runner_cd_closure_next_blocked_step_action" - ] == ( - "run_register_awoooi_non110_runner_script_without_printing_token_then_autostart_path_will_enable_service_and_rerun_this_verifier" - ) - assert data["summary"]["production_deploy_non110_runner_ready"] is False + ] == "complete_authorized_cd_then_verify_image_tag_matches_main" + assert data["summary"]["production_deploy_non110_runner_ready"] is True assert ( data["summary"][ "production_deploy_non110_runner_prepare_only_source_ready" @@ -185,7 +183,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): ) assert ( data["summary"]["production_deploy_non110_runner_online_label_match"] - is False + is True ) assert ( data["summary"]["production_deploy_non110_runner_autostart_path_armed"] @@ -207,14 +205,14 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): assert data["summary"]["production_deploy_non110_runner_ready_service_count"] == 1 assert ( data["summary"]["production_deploy_non110_runner_ready_registration_count"] - == 0 + == 1 ) assert data["summary"]["production_deploy_non110_runner_safe_next_step"] == ( - "run_register_awoooi_non110_runner_script_without_printing_token_then_autostart_path_will_enable_service_and_rerun_this_verifier" + "complete_authorized_cd_then_verify_image_tag_matches_main" ) assert ( data["summary"]["production_deploy_non110_runner_remaining_blocker_count"] - == 3 + == 0 ) assert ( data["summary"][ @@ -288,12 +286,12 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): assert lanes["release"]["metric"]["total"] == 5 assert lanes["production_deploy"]["metric"]["kind"] == "deploy_readback" assert lanes["production_deploy"]["status"] == ( - "blocked_waiting_authorized_gitea_workflow_dispatch_and_runner_queue" + "blocked_production_image_not_current" ) - assert lanes["production_deploy"]["blocker_count"] == 3 + assert lanes["production_deploy"]["blocker_count"] == 2 assert lanes["production_deploy"]["metric"][ "observed_source_control_main_short_sha" - ] == "f3634db18477" + ] == "1ca806fd5d28" assert lanes["production_deploy"]["metric"][ "production_image_tag_short_sha" ] == "af45811e87" @@ -383,7 +381,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): ) assert ( lanes["production_deploy"]["metric"]["non110_runner_cd_closure_status"] - == "blocked_non110_runner_not_ready" + == "blocked_production_image_not_current" ) assert ( lanes["production_deploy"]["metric"]["non110_runner_cd_closure_required"] @@ -403,44 +401,42 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_ordered_completed_prefix_count" ] - == 0 + == 4 ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_evidence_completed_step_count" ] - == 2 + == 4 ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_ordered_completion_percent" ] - == 0 + == 67 ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_evidence_completion_percent" ] - == 33 + == 67 ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_next_blocked_step_index" ] - == 1 + == 5 ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_next_blocked_step_id" ] - == "non110_runner_registration_metadata" + == "production_image_tag_current" ) assert lanes["production_deploy"]["metric"][ "non110_runner_cd_closure_next_blocked_step_action" - ] == ( - "run_register_awoooi_non110_runner_script_without_printing_token_then_autostart_path_will_enable_service_and_rerun_this_verifier" - ) - assert lanes["production_deploy"]["metric"]["non110_runner_ready"] is False + ] == "complete_authorized_cd_then_verify_image_tag_matches_main" + assert lanes["production_deploy"]["metric"]["non110_runner_ready"] is True assert ( lanes["production_deploy"]["metric"][ "non110_runner_prepare_only_source_ready" @@ -469,7 +465,7 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): ) assert ( lanes["production_deploy"]["metric"]["non110_runner_online_label_match"] - is False + is True ) assert ( lanes["production_deploy"]["metric"]["non110_runner_autostart_path_armed"] @@ -493,16 +489,16 @@ def test_delivery_closure_workbench_endpoint_returns_product_summary(): lanes["production_deploy"]["metric"][ "non110_runner_ready_registration_count" ] - == 0 + == 1 ) assert lanes["production_deploy"]["metric"]["non110_runner_safe_next_step"] == ( - "run_register_awoooi_non110_runner_script_without_printing_token_then_autostart_path_will_enable_service_and_rerun_this_verifier" + "complete_authorized_cd_then_verify_image_tag_matches_main" ) assert ( lanes["production_deploy"]["metric"][ "non110_runner_remaining_blocker_count" ] - == 3 + == 0 ) assert lanes["github"]["metric"]["kind"] == "private_backup_verified" assert lanes["gitea"]["metric"]["kind"] == "workflow_count" diff --git a/docs/LOGBOOK.md b/docs/LOGBOOK.md index 839b8ea4..9ca6e691 100644 --- a/docs/LOGBOOK.md +++ b/docs/LOGBOOK.md @@ -1,3 +1,25 @@ +## 2026-06-29 — 11:08 non-110 runner ready / production image blocker 收斂 + +**完成內容**: +- 使用 sanitized readiness artifact `/tmp/awoooi-non110-readiness-20260629-current.txt` 讀回 `AWOOOI_NON110_RUNNER_READY=1`、registration/service/active/autostart counts 全為 `1`、`BLOCKER_COUNT=0`。 +- Public Gitea queue readback 轉為 `status=no_matching_runner_not_visible`,不再把 `awoooi-non110-ubuntu` 視為 no-matching runner blocker。 +- Production deploy snapshot 與 Delivery Workbench 測試改為 `non110_runner_ready=true`、`non110_runner_remaining_blocker_count=0`、`next_blocked_step_id=production_image_tag_current`、`ordered_completion_percent=67`。 +- 目前 closure verifier 讀回 `status=blocked_production_image_not_current`,剩餘 blocker 是 production image tag 尚未跟目前 Gitea main 對齊,以及 governance fields 尚未在 production Workbench 出現。 + +**邊界**:未讀 token / `.runner` 內容 / cookie / session / secret / auth / `.env`;未 workflow_dispatch,未手改 K8s tag,未使用 GitHub,未 force push。 + +## 2026-06-29 — 11:09 non-110 runner ready live readback + +**完成內容**: +- 188 live readiness verifier 讀回 `.runner` registration metadata 已存在但 `content_read=false`;`awoooi-non110-runner.service` 已 `ActiveState=active`,target binary / config verified,autostart path 仍 armed。 +- `READY_CONFIG_COUNT=1`、`READY_BINARY_COUNT=1`、`READY_REGISTRATION_COUNT=1`、`READY_SERVICE_COUNT=1`、`READY_ACTIVE_SERVICE_COUNT=1`、`READY_AUTOSTART_PATH_COUNT=1`、`AWOOOI_NON110_RUNNER_READY=1`。 +- public queue readback 目前 `no_matching_runner_not_visible`;closure ordered progress 前四步 evidence ready,`ordered_completion_percent=67`,下一 blocked step 改為 `production_image_tag_current`。 +- production deploy snapshot / Delivery Workbench test 更新為 `blocked_production_image_not_current`,`non110_runner_remaining_blocker_count=0`。 + +**仍維持**: +- Production image tag 仍為 `af45811e87`,尚未對齊目前 Gitea main;governance writeback fields 尚未出現。 +- 未讀 token / `.runner` 內容 / cookie / session / secret / auth / `.env`;未手動 workflow_dispatch,未操作 Docker / K8s / host runtime,未使用 GitHub。 + ## 2026-06-29 — 10:58 non-110 CD closure ordered progress readback **完成內容**: diff --git a/docs/operations/awoooi-production-deploy-readback-blocker.snapshot.json b/docs/operations/awoooi-production-deploy-readback-blocker.snapshot.json index 1f12f987..1f844460 100644 --- a/docs/operations/awoooi-production-deploy-readback-blocker.snapshot.json +++ b/docs/operations/awoooi-production-deploy-readback-blocker.snapshot.json @@ -5,8 +5,8 @@ "priority": "P0", "scope": "awoooi_production_truth", "readback": { - "observed_source_control_main_sha": "f3634db18477a06af94ec4eae227ee96378aae0a", - "observed_source_control_main_short_sha": "f3634db18477", + "observed_source_control_main_sha": "1ca806fd5d287c143f09c8d6c82d3a228cc0ef2a", + "observed_source_control_main_short_sha": "1ca806fd5d28", "governance_closure_merge_sha": "27b96f0450d0e3ca6651d6b5f274a341dd727ef2", "governance_closure_commit_sha": "9e3e7fbb6ba3ffd324b45abf3ad1e7b6ec826b22", "production_image_tag_sha": "af45811e876fda322ee63c036fbc39c9f07ffd76", @@ -67,12 +67,12 @@ }, "blockers": [ { - "id": "authorized_gitea_workflow_dispatch_channel_missing", - "kind": "external_authorized_control_channel", + "id": "production_governance_fields_missing_until_current_cd", + "kind": "production_readback", "severity": "P0", - "description": "Source 已進 Gitea main,但 production image tag 仍停在舊 SHA;目前沒有可用的已授權 Gitea workflow_dispatch channel 觸發最新 cd.yaml。", - "blocked_action": "deploy_current_gitea_main_to_production", - "safe_boundary": "不得讀 token/cookie/session,不得改 workflow 為 push trigger,不得手改 K8s tag,不得重開 110 runner 或 host/K8s runtime。" + "description": "Production Delivery Workbench 尚未出現 internal_governance_writeback / KM / PlayBook counters;必須等目前 main 經 Gitea CD 部署後再讀回。", + "blocked_action": "verify_governance_fields_after_current_main_cd", + "safe_boundary": "不得讀 token/cookie/session,不得手改 K8s tag,不得使用 GitHub,不得操作 host/Docker/K8s。" }, { "id": "production_image_tag_not_current_after_non110_ready",