Skip to content

fix: release.yml lowercase image name (hotfix promote to main)#48

Merged
Setounkpe7 merged 2 commits into
mainfrom
dev
May 28, 2026
Merged

fix: release.yml lowercase image name (hotfix promote to main)#48
Setounkpe7 merged 2 commits into
mainfrom
dev

Conversation

@Setounkpe7

Copy link
Copy Markdown
Owner

Summary

Promotes the release.yml hotfix (PR #47) from `dev` to `main` so the next `release.yml` run produces a fully signed and SBOM-attested image.

Background: First main-branch `release.yml` run (26557127655) successfully pushed the image to GHCR at `ghcr.io/setounkpe7/threat-intel-api:sha-ff51baa` / `:main` / `:latest`, but the subsequent Trivy SBOM step failed because our env-built digest reference kept the uppercase `S` from `github.repository_owner`. The signing/attestation chain never ran.

This PR fixes that by lowercasing `IMAGE_NAME` in a step right after Checkout. On merge to `main`, `release.yml` re-fires and produces the missing signature + SBOM attestation + SLSA L2 provenance for the new merge-commit image.

Test plan

🤖 Generated with Claude Code

Setounkpe7 and others added 2 commits May 28, 2026 01:49
GHCR (like all OCI registries) requires lowercase image references.
github.repository_owner preserves the user's mixed-case login
("Setounkpe7"), so:

  IMAGE_NAME=Setounkpe7/threat-intel-api

The metadata-action lowercases tags for the push step automatically,
so `docker push` succeeded on the first main-branch run. But our
env-built digest reference

  ${REGISTRY}/${IMAGE_NAME}@${digest}
  -> ghcr.io/Setounkpe7/threat-intel-api@sha256:...

was passed verbatim to Trivy, cosign sign, cosign attest, and the
smoke-verify step. Trivy failed first on run 26557127655 with:

  unable to initialize container image: failed to parse the image
  name: could not parse reference

Aborting the rest of the chain — image was pushed to GHCR but never
got its CycloneDX SBOM attestation, cosign signature, or SLSA L2
build provenance.

Fix: insert a one-line step right after Checkout that tr-lowercases
IMAGE_NAME and writes it back to GITHUB_ENV. All downstream steps
then see the canonical lowercased value via env.IMAGE_NAME / IMAGE_NAME.
…e-name

fix(release): lowercase IMAGE_NAME for GHCR refs
@Setounkpe7 Setounkpe7 merged commit 8768ae0 into main May 28, 2026
11 checks passed
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