Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Align OCI artifacts with upstream guidance #11049

Merged
merged 3 commits into from
Sep 29, 2023

Conversation

neersighted
Copy link
Member

@neersighted neersighted commented Sep 28, 2023

What I did

Make some slight tweaks to the code that produces and consumes Compose files as OCI artifacts in order to align with upstream best practices/the official guidance.

Manifest before:

{
        "schemaVersion": 2,
        "mediaType": "application/vnd.oci.image.manifest.v1+json",
        "artifactType": "application/vnd.docker.compose.project",
        "config": {
                "mediaType": "application/vnd.docker.compose.project",
                "digest": "sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
                "size": 2,
                "annotations": {
                        "com.docker.compose.version": "2.22.0"
                }
        },
        "layers": [
                {
                        "mediaType": "application/vnd.docker.compose.file+yaml",
                        "digest": "sha256:839ee3e27293c4f021ad49d8e71ec85bfc69706d1f06037b848a4f13564eeba8",
                        "size": 343,
                        "annotations": {
                                "com.docker.compose": "2.22.0"
                        }
                }
        ]
}

Manifest after:

{
        "schemaVersion": 2,
        "mediaType": "application/vnd.oci.image.manifest.v1+json",
        "artifactType": "application/vnd.docker.compose.project",
        "config": {
                "mediaType": "application/vnd.oci.empty.v1+json",
                "digest": "sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
                "size": 2
        },
        "layers": [
                {
                        "mediaType": "application/vnd.docker.compose.file+yaml",
                        "digest": "sha256:839ee3e27293c4f021ad49d8e71ec85bfc69706d1f06037b848a4f13564eeba8",
                        "size": 343,
                        "annotations": {
                                "com.docker.compose.version": "2.22.0"
                        }
                }
        ]
}

Related issue
N/A

Copy link
Contributor

@ndeloof ndeloof left a comment

Choose a reason for hiding this comment

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

👍

@codecov
Copy link

codecov bot commented Sep 29, 2023

Codecov Report

Attention: 7 lines in your changes are missing coverage. Please review.

Comparison is base (bd74a92) 57.44% compared to head (6dcdcc2) 57.57%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #11049      +/-   ##
==========================================
+ Coverage   57.44%   57.57%   +0.13%     
==========================================
  Files         129      129              
  Lines       11232    11229       -3     
==========================================
+ Hits         6452     6465      +13     
+ Misses       4149     4135      -14     
+ Partials      631      629       -2     
Files Coverage Δ
pkg/compose/publish.go 0.00% <0.00%> (ø)
pkg/remote/oci.go 2.38% <0.00%> (ø)

... and 5 files with indirect coverage changes

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

@ndeloof ndeloof merged commit 12e0ac8 into docker:main Sep 29, 2023
@neersighted neersighted deleted the oci_artifacts branch September 29, 2023 03:54
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