Skip to content

feat: add oci image metadata - #2300

Merged
TerryHowe merged 3 commits into
oras-project:mainfrom
MindTooth:feat/oci-image-metadata
Oct 26, 2026
Merged

TerryHowe merged 3 commits into
oras-project:mainfrom
MindTooth:feat/oci-image-metadata

Conversation

@MindTooth

@MindTooth MindTooth commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:

When Renovate is opening updates, it looks for changelogs from e.g. GitHub (this project). But, since the current containers build from this project do not contain org.opencontainers.image.source, Renovate do not know where to go to fetch these.

I had Codex add the labels. Manual verification locally with Apple container. Made Codex do a writeup of the steps I did:


Testing

Local image validation — passed

Built the image on macOS (Apple Silicon) using Apple Container:

container build \
  --build-arg OCI_VERSION=v1.4.0 \
  --build-arg OCI_REVISION="$(git rev-parse HEAD)" \
  -t oras:oci-test .

Verified the OCI labels:

container image inspect oras:oci-test |
  jq '.[0].variants[0].config.config.Labels'

Result: All nine OCI labels were present, including:

org.opencontainers.image.source=https://github.com/oras-project/oras
org.opencontainers.image.version=v1.4.0
org.opencontainers.image.revision=8c5267045b374dfbdf10b112016973a0d759cbde

Verified CLI execution:

container run --rm oras:oci-test version

Output:

Version:        1.3.6
Go version:     go1.27.2
OS/Arch:        linux/arm64
Git commit:     8c5267045b374dfbdf10b112016973a0d759cbde
Git tree state: clean

The OCI version label was explicitly set to v1.4.0 for testing; it does not represent the compiled CLI version.


Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
N/A.

Please check the following list:

  • Does the affected code have corresponding tests, e.g. unit test, E2E test?
  • Does this change require a documentation update?
  • Does this introduce breaking changes that would require an announcement or bumping the major version?
  • Do all new files have an appropriate license header?

Signed-off-by: Birger Johan Nordølum <[email protected]>
Signed-off-by: Birger Johan Nordølum <[email protected]>
@codecov

codecov Bot commented Oct 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 61.85%. Comparing base (bc7b32d) to head (8c52670).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2300   +/-   ##
=======================================
  Coverage   61.85%   61.85%           
=======================================
  Files         140      140           
  Lines        6098     6098           
=======================================
  Hits         3772     3772           
  Misses       2102     2102           
  Partials      224      224           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TerryHowe TerryHowe left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@TerryHowe
TerryHowe merged commit 4962d0f into oras-project:main Oct 26, 2026
10 checks passed
@TerryHowe

Copy link
Copy Markdown
Member

Thanks!

TerryHowe pushed a commit to oras-project/oras-www that referenced this pull request Nov 19, 2026
Fixes #701 (part of #697)

Adds a blog post announcing ORAS CLI v1.4.0 at
`blog/2026-11-19-oras-1.4.0/index.mdx`. It follows the format of the
v1.3.0 post and uses the `oras` author like the other release posts.

It covers the topics listed in the issue:

- the move to oras-go v3, with a link to the oras-go v3.0.0 post
- `oras copy` with separate credentials on the same registry
(oras-project/oras#1892) and the GitLab login fix
(oras-project/oras#2260)
- the experimental `ORAS_EXPERIMENTAL_CONTAINERS_CONFIG` mode
- `oras blob fetch`/`delete` requiring digests (oras-project/oras#2304)
and header flags rejected for OCI layout targets
(oras-project/oras#2299)
- OCI image labels (oras-project/oras#2300) and build provenance
attestations

It also links the installation page and the full release notes.

The containers config section doesn't link a how-to guide yet because
#700 is still open. I can add the link once that guide lands.

Tested locally: `npm run check-links` passes, and the post renders
correctly with `npm start` at `/blog/oras-v1.4.0`.

I used Claude to help draft this post, and I checked the content against
the v1.4.0 release notes.

---------

Signed-off-by: Ashwanijha1405 <[email protected]>
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.

2 participants