fix(agent): verify host110 harbor backend route

This commit is contained in:
ogt
2026-07-14 19:39:47 +08:00
parent 7f58f844f4
commit 177040c273
4 changed files with 41 additions and 23 deletions

View File

@@ -448,7 +448,7 @@ _CATALOG: tuple[dict[str, Any], ...] = (
"auto_apply_enabled": True,
"approval_required": False,
"risk_level": "medium",
"catalog_revision": "2026-07-14-host110-inputs-v2",
"catalog_revision": "2026-07-14-host110-harbor-route-v3",
},
{
"catalog_id": "ansible:188-momo-backup-user",

View File

@@ -109,7 +109,9 @@ _POSTCONDITION_REGISTRY: dict[str, tuple[AssetPostcondition, ...]] = {
"host_110_harbor_route",
"route",
"host_110",
"test -s /etc/nginx/sites-enabled/harbor.conf && systemctl is-active --quiet nginx",
"status=$(curl -sS -o /dev/null -w '%{http_code}' --max-time 10 "
"http://127.0.0.1:5000/v2/); "
"[ \"$status\" = 200 ] || [ \"$status\" = 401 ]",
),
AssetPostcondition(
"host_110_backup_assets",