Skip to content

Commit 6361ac1

Browse files
committed
Make "tags" arch-specific again
This fixes edge case bugs where tags which share a sourceId but across disparate architectures will be grouped. This can be seen concretely in https://oci.dag.dev/?image=infosiftr/moby:s390x@sha256:9a423230716c0f934e2fffa46585df1b2babc96ea0a1dd01bbd6ce29c6233aea (where `infosiftr/moby:s390x` should be _just_ the s390x build, but instead gets _all_ the architecture builds which share that same sourceId).
1 parent 21643d6 commit 6361ac1

File tree

12 files changed

+1038
-860
lines changed

12 files changed

+1038
-860
lines changed

.test/builds.json

Lines changed: 425 additions & 481 deletions
Large diffs are not rendered by default.

.test/deploy-all/out.json

Lines changed: 158 additions & 67 deletions
Large diffs are not rendered by default.

.test/deploy-all/test.jq

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
include "deploy";
22

33
# every single ref both "library/" and arch-specific we should push to
4-
tagged_manifests(true; .source.tags, .source.arches[.build.arch].archTags)
4+
tagged_manifests(true; .source.arches[.build.arch].tags, .source.arches[.build.arch].archTags)
55
# ... converted into a list of canonical inputs for "cmd/deploy"
66
| deploy_objects

.test/meta-commands/test.jq

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ include "meta";
1010
| commands
1111
| to_entries
1212
| map("# <\(.key)>\n\(.value)\n# </\(.key)>")
13-
| "# \($b.source.tags[0]) [\($b.build.arch)]\n" + join("\n")
13+
| "# \($b.source.arches[$b.build.arch].tags[0]) [\($b.build.arch)]\n" + join("\n")
1414
)
1515
| join("\n\n")

0 commit comments

Comments
 (0)