Skip to content

list all pushed tags in the json metadata output of oras push #1341

Closed

Description

@qweeah

What is the version of your ORAS CLI

1.2.0-beta.1

What would you like to be added?

Currently all the pushed tags are displayed in the output but not in the json output of oras push

$ oras push localhost:5000/test:tag1,tag2,tag3 --format json
✓ Uploaded  application/vnd.oci.empty.v1+json                                                                                    2/2  B 100.00%   48ms
  └─ sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a
✓ Uploaded  application/vnd.oci.image.manifest.v1+json                                                                       535/535  B 100.00%   38ms
  └─ sha256:0a6d04eceb050df7446931a07d75d3465b28bd8616003eddcce6838cfdcd3995
Tagged tag3
Tagged tag2
{
  "Ref": "localhost:5000/test@sha256:0a6d04eceb050df7446931a07d75d3465b28bd8616003eddcce6838cfdcd3995",
  "MediaType": "application/vnd.oci.image.manifest.v1+json",
  "Digest": "sha256:0a6d04eceb050df7446931a07d75d3465b28bd8616003eddcce6838cfdcd3995",
  "Size": 535,
  "Annotations": {
    "org.opencontainers.image.created": "2024-04-12T08:26:14Z"
  },
  "ArtifactType": "application/vnd.unknown.artifact.v1"
}

Why is this needed for ORAS?

Pushed tags tag1 tag2 and tag3 should be added to the json output of oras push and selectable via go templating.

Are you willing to submit PRs to contribute to this feature?

  • Yes, I am willing to implement it.

Activity

  1. added
    enhancement
    triage
    on Apr 12, 2024
  2. added this to the v1.2.0 milestone on Apr 12, 2024
  3. qweeah commented on Apr 16, 2024

    @qweeah
    ContributorAuthor

    As is suggested in #1199 (comment) and #1199 (comment), the field should be full reference ending with tags.

  4. FeynmanZhou commented on Apr 16, 2024

    @FeynmanZhou
    Member

    @qweeah tags is also recommended to be outputted in oras attach.

  5. qweeah commented on Apr 16, 2024

    @qweeah
    ContributorAuthor

    @qweeah tags is also recommended to be outputted in oras attach.

    What value should be put into this field? oras attach cannot tag artifact.

  6. removed
    triage
    on Apr 16, 2024
  7. FeynmanZhou commented on Apr 16, 2024

    @FeynmanZhou
    Member

    @qweeah You are right. oras attach will not produce new tags so it's not necessary to show tags in the output. Ignore my suggestion above.

  8. self-assigned this
    on Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancement

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions