From 73926ac5e6e85212eff035301cb095d8fb9b83ec Mon Sep 17 00:00:00 2001 From: Danyang Chen Date: Fri, 4 Dec 2026 01:07:15 +0800 Subject: [PATCH] runtime image: name the pinned upstream version in the description labelRelated #3503 --- runtime/flybot-image/Dockerfile | 2 +- scripts/verify-reuse-audit-pins.py | 14 +++++++++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/runtime/flybot-image/Dockerfile b/runtime/flybot-image/Dockerfile index e501f5d3b..88665edb0 100644 --- a/runtime/flybot-image/Dockerfile +++ b/runtime/flybot-image/Dockerfile @@ -138,7 +138,7 @@ HEALTHCHECK --interval=10s --timeout=3s --start-period=20s --start-interval=500m CMD ["sh", "/opt/flybot-workspace/runtime/flybot-image/healthcheck.sh"] LABEL org.opencontainers.image.title="FlyBot FlyBot runtime" \ - org.opencontainers.image.description="Self-host FlyBot runtime: unmodified DS-Bot v0.3.6 plus the social host adapter, served by dsh web on 8080." \ + org.opencontainers.image.description="Self-host FlyBot runtime: unmodified DS-Bot v0.4.3 plus the social host adapter, served by dsh web on 8080." \ org.opencontainers.image.source="https://github.com/ThinkFlowLab/FlyBot" \ org.opencontainers.image.licenses="MIT AND Apache-2.0" diff --git a/scripts/verify-reuse-audit-pins.py b/scripts/verify-reuse-audit-pins.py index bda44ec01..420d23c13 100755 --- a/scripts/verify-reuse-audit-pins.py +++ b/scripts/verify-reuse-audit-pins.py @@ -11,6 +11,7 @@ import argparse import hashlib import json +import re import sys import urllib.request from pathlib import Path @@ -137,6 +138,7 @@ def check_shipped() -> int: errors += 1 else: print("OK DSH git tag", DSH_TAG_COMMIT, "correspondence still unverified") + dockerfile = (ROOT / "runtime/flybot-image/Dockerfile").read_text() pin_path = ROOT / "runtime" / "ds-bot-upstream.pin.json" if not pin_path.is_file(): print("FAIL: missing runtime/ds-bot-upstream.pin.json") @@ -183,6 +185,17 @@ def check_shipped() -> int: errors += 1 elif expected_upstream: print(f"OK root NOTICE names the vendored upstream {expected_upstream}") + pin_name = pin_repo.rsplit("/", 1)[-1] + expected_label = f"{pin_name} {pin_tag}".strip() + label = re.search(r'org\.opencontainers\.image\.description="([^"]*)"', dockerfile) + if not label: + print("FAIL: image recipe has no org.opencontainers.image.description label") + errors += 1 + elif expected_label and expected_label not in label.group(1): + print(f"FAIL: image recipe description label does not name the vendored upstream {expected_label}") + errors += 1 + else: + print(f"OK image recipe description label names the vendored upstream {expected_label}") if kit.get("license") != LIBREOFFICE_LICENSE or "blocker" not in (kit.get("redistribution") or ""): print("FAIL: libreoffice-kit MPL clearance blocker not recorded") errors += 1 @@ -191,7 +204,6 @@ def check_shipped() -> int: errors += 1 else: print("OK libreoffice-kit MPL-2.0 clearance still blocked; source offer recorded") - dockerfile = (ROOT / "runtime/flybot-image/Dockerfile").read_text() if "does not close issue" in dockerfile.lower() or "closes issue" in dockerfile.lower(): print("FAIL: Dockerfile uses GitHub closing-keyword phrasing") errors += 1