Skip to content

Commit d1211b3

Browse files
committed
Orchestrator: enforce mandatory CI artifact fetch & update docs
1 parent a87f23d commit d1211b3

File tree

6 files changed

+23
-24
lines changed

6 files changed

+23
-24
lines changed

docs/release-steps.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ make release # for first publication
5858
```
5959
You will see:
6060
1. Local build presence check (or build via prerequisites).
61-
2. CI artifact fetch attempt (Debian workflow artifacts).
61+
2. CI artifact fetch (MANDATORY). Failure to retrieve artifacts aborts; you must wait for the workflow to finish.
6262
3. sha256 comparison (local vs CI). If any differ, release ABORTS by default (no prompt) to enforce deterministic provenance.
6363
- To force using local artifacts: `KEYCHAIN_FORCE_LOCAL=1 make release`
6464
- To adopt CI artifacts: `KEYCHAIN_ADOPT_CI=1 make release`

scripts/fetch-ci-artifacts.sh

100644100755
File mode changed.

scripts/release-common.sh

100644100755
File mode changed.

scripts/release-create.sh

100644100755
File mode changed.

scripts/release-orchestrate.sh

100644100755
Lines changed: 22 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -20,38 +20,37 @@ for f in keychain-$VER.tar.gz keychain keychain.1; do
2020
[ -f "$f" ] || { echo "Missing local asset: $f" >&2; exit 1; }
2121
done
2222

23-
# 2. Fetch CI artifacts (if available)
23+
# 2. Fetch CI artifacts (MANDATORY)
2424
CI_DIR=".ci-artifacts-$VER"
2525
rm -rf "$CI_DIR"
26-
if ./scripts/fetch-ci-artifacts.sh "$VER" "$CI_DIR" 2>/dev/null; then
27-
echo "CI artifacts retrieved." >&2
28-
else
29-
echo "Warning: Could not fetch CI artifacts for $VER (maybe workflow not finished yet)." >&2
30-
CI_DIR=""
26+
echo "Fetching CI artifacts for $VER (mandatory step)..." >&2
27+
if ! ./scripts/fetch-ci-artifacts.sh "$VER" "$CI_DIR"; then
28+
echo "ERROR: Unable to retrieve CI artifacts for $VER. Release aborted." >&2
29+
echo "Hint: Ensure the GitHub Actions 'release' workflow for tag $VER has completed successfully." >&2
30+
echo " Re-run 'make release' once artifacts are available." >&2
31+
exit 1
3132
fi
33+
echo "CI artifacts retrieved." >&2
3234

3335
calc_sha256() { sha256sum "$1" | awk '{print $1}'; }
3436

3537
diff_flag=0
36-
if [ -n "$CI_DIR" ]; then
37-
echo "Digest comparison (sha256):"
38-
for artifact in keychain-$VER.tar.gz keychain keychain.1; do
39-
if [ -f "$CI_DIR/$artifact" ]; then
40-
L=$(calc_sha256 "$artifact")
41-
R=$(calc_sha256 "$CI_DIR/$artifact")
42-
if [ "$L" = "$R" ]; then
43-
printf ' %-20s %s (match)\n' "$artifact" "$L"
44-
else
45-
printf ' %-20s LOCAL %s != CI %s *DIFF*\n' "$artifact" "$L" "$R"
46-
diff_flag=1
47-
fi
38+
echo "Digest comparison (sha256):"
39+
for artifact in keychain-$VER.tar.gz keychain keychain.1; do
40+
if [ -f "$CI_DIR/$artifact" ]; then
41+
L=$(calc_sha256 "$artifact")
42+
R=$(calc_sha256 "$CI_DIR/$artifact")
43+
if [ "$L" = "$R" ]; then
44+
printf ' %-20s %s (match)\n' "$artifact" "$L"
4845
else
49-
printf ' %-20s CI copy missing; skipping comparison\n' "$artifact"
46+
printf ' %-20s LOCAL %s != CI %s *DIFF*\n' "$artifact" "$L" "$R"
47+
diff_flag=1
5048
fi
51-
done
52-
else
53-
echo "Skipping digest comparison (no CI artifacts)."
54-
fi
49+
else
50+
printf ' %-20s CI copy missing; comparison failed (abort)\n' "$artifact"
51+
diff_flag=1
52+
fi
53+
done
5554

5655
if [ $diff_flag -ne 0 ]; then
5756
echo

scripts/release-refresh.sh

100644100755
File mode changed.

0 commit comments

Comments
 (0)