Skip to content

images, scripts: small hardening - #44

Open
vtushar06 wants to merge 2 commits into
podman-container-tools:mainfrom
vtushar06:ci-hardening
Open

images, scripts: small hardening#44
vtushar06 wants to merge 2 commits into
podman-container-tools:mainfrom
vtushar06:ci-hardening

Conversation

@vtushar06

Copy link
Copy Markdown
Contributor

Two small things I ran into while looking at the image scripts.

The cache list in images/local-cache-registry has testdigest_v2s2:20200210 twice (lines 87 and 94), so image builds do one extra full skopeo copy of it from quay. Harmless, just redundant.

The release upload curl in scripts/upload-to-oci-par.sh has no --retry, and with set -e a single transient failure aborts the loop mid-way - some artifacts uploaded, no release created. The release job comment already mentions hoping for better network, so this seemed worth hardening. I used --retry 5 to match images/build.sh, plus --retry-all-errors since plain --retry does not retry 5xx under --fail. The PUT is idempotent so retrying should be safe.

I only tested that both scripts still parse - I can't exercise the release path myself.

testdigest_v2s2:20200210 is listed twice, so cache_images does a second
skopeo copy of the same image from quay on every image build.

Signed-off-by: Tushar Verma <tusharmyself06@gmail.com>
The upload curl has no retry and the loop runs under set -e, so one
transient error aborts it with some artifacts uploaded and no release
created. --retry 5 matches images/build.sh; --retry-all-errors is
needed because plain --retry does not cover 5xx under --fail, and the
PAR upload is idempotent.

Signed-off-by: Tushar Verma <tusharmyself06@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant