Open toddysm opened 1 year ago
I expect the command to output correct information about all artifacts that are copied and provide a summary
Sorry I must miss something here, are you suggesting all the nodes should be mentioned in the output even if --verbose
is not set?
I think there are some gaps that need to be filled here: originally oras was designed as a client tool to upload/download files to/from OCI registries. IMHO, to expose less low-level storage detail like how a file is stored via OCI image/artifacts, unnamed manifests and blobs should not be in the default output of oras. For example, if you run oras pull
on the signature artifact, only the copy-testimage-latest.json
will be copied to your local file system:
$ oras pull ghcr.io/toddysm/cssc-pipeline/copy-testimage@sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7 -T --include-subject
Downloading 2eb165eb8127 /Users/toddysm/Documents/Development/kubecon-eu-2023-talks/sboms/copy-testimage-latest.json
Downloaded 2eb165eb8127 /Users/toddysm/Documents/Development/kubecon-eu-2023-talks/sboms/copy-testimage-latest.json
Pulled [registry] ghcr.io/toddysm/cssc-pipeline/copy-testimage@sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7
Digest: sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7
Same for copy-testimage-latest.json
$ oras pull ghcr.io/toddysm/cssc-pipeline/copy-testimage@sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7 -T --include-subject
Downloading 2eb165eb8127 /Users/toddysm/Documents/Development/kubecon-eu-2023-talks/sboms/copy-testimage-latest.json
Downloaded 2eb165eb8127 /Users/toddysm/Documents/Development/kubecon-eu-2023-talks/sboms/copy-testimage-latest.json
Pulled [registry] ghcr.io/toddysm/cssc-pipeline/copy-testimage@sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7
Digest: sha256:914ec14e0ff6f79f2f9df3dbb03421fdb9d4cdbfaf0313198b72b62f127e04a7
So for oras cp
, only copy-testimage-latest.json
and copy-testimage-latest.json
is shown in the default output.
Sorry I must miss something here, are you suggesting all the nodes should be mentioned in the output even if --verbose is not set?
Correct, this is what I expect. I have 6 artifacts that I am copying but I see only 3 outputted by the command. This is misleading.
Correct, this is what I expect. I have 6 artifacts that I am copying but I see only 3 outputted by the command. This is misleading.
I am okay with this change, since oras cp
doesn't operate file store at all, the user usually care more about artifacts/images than files.
What happened in your environment?
I have the following hierarchy in one registry:
I am using
oras copy -r
to copy the above hierarchy to another registry. The command ouputs the following:The output shows only three artifacts copied to the new registry, which leaves the user wondering whether all artifacts have been copied. In reality all are, but the command output is misleading. Here is the tree in the new registry:
What did you expect to happen?
I expect the command to output correct information about all artifacts that are copied and provide a summary
How can we reproduce it?
Use
oras copy -r
on a deep hierarchyWhat is the version of your ORAS CLI?
Version: 1.0.0-rc.2 Go version: go1.20.1 Git commit: 3c5e899f6f32299080074e665ba7c44e25aa639f Git tree state: clean
What is your OS environment?
MacOS
Are you willing to submit PRs to fix it?