mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-10-26 05:29:45 +00:00
b09ba017eb
The first beta's release workflow failed in publish_docker at "Verify exact tags and signed provenance": gh attestation verify copied an image blob from Docker Hub and got a 502 Bad Gateway. The verifier calls docker buildx imagetools inspect and gh attestation verify against Docker Hub and GHCR with no tolerance for a transient registry error, so one 5xx fails the whole release, and the train can rerun it only once. Retry each of those reads up to four times with doubling backoff from 10 seconds. They are idempotent, and a moved tag or an invalid attestation fails identically on every attempt, so a real failure is delayed by the backoff and never masked. This script's stdout is the step output, so each attempt's stdout is captured and only the successful attempt's is emitted: a failed read that printed half a manifest cannot corrupt the verified digests. VERIFY_REGISTRY_ATTEMPTS and VERIFY_REGISTRY_WAIT_SECONDS tune it, validated as small whole numbers so the retry stays bounded. Test it with doubles that fail like a dropped connection: transient attestation reads are retried and only the digest proof is emitted; a digest read that prints a partial manifest before failing leaves no trace in the output; and an exhausted attempt budget fails with an explicit error and no output. The old assertion that an unverifiable attestation costs exactly one read now expects the four attempts. Against the previous script the new tests fail. The contract records the retry. Contract-Neutral: Release verification reliability only; no published artifact, tag, signing, install or customer contract changes.