@@ -137,57 +137,6 @@ jq -s '
137137 )
138138' temp/index.json > temp/index.json.new
139139mv temp/index.json.new temp/index.json
140- # </build>
141- # <push>
142- crane push --index temp ' oisupport/staging-amd64:191402ad0feacf03daf9d52a492207e73ef08b0bd17265043aea13aa27e2bb3f'
143- rm -rf temp
144- # </push>
145-
146- # busybox:1.36.1 [arm32v5]
147- # <pull>
148-
149- # </pull>
150- # <build>
151- export BASHBREW_CACHE=" ${BASHBREW_CACHE:- ${XDG_CACHE_HOME:- $HOME / .cache} / bashbrew} "
152- gitCache=" $BASHBREW_CACHE /git"
153- git init --bare " $gitCache "
154- _git () { git -C " $gitCache " " $@ " ; }
155- _git config gc.auto 0
156- _commit () { _git rev-parse ' 7044abc7ee26712d998311b402b975124786e0cf^{commit}' ; }
157- if ! _commit & > /dev/null; then _git fetch ' https://github.com/docker-library/busybox.git' ' 7044abc7ee26712d998311b402b975124786e0cf:' || _git fetch ' refs/heads/dist-arm32v5:' ; fi
158- _commit
159- mkdir temp
160- _git archive --format=tar ' 7044abc7ee26712d998311b402b975124786e0cf:latest/glibc/arm32v5/' | tar -xvC temp
161- jq -s '
162- if length != 1 then
163- error("unexpected ' \' ' oci-layout' \' ' document count: " + length)
164- else .[0] end
165- | if .imageLayoutVersion != "1.0.0" then
166- error("unsupported imageLayoutVersion: " + .imageLayoutVersion)
167- else . end
168- ' temp/oci-layout > /dev/null
169- jq -s '
170- if length != 1 then
171- error("unexpected ' \' ' index.json' \' ' document count: " + length)
172- else .[0] end
173- | if .schemaVersion != 2 then
174- error("unsupported schemaVersion: " + .schemaVersion)
175- else . end
176- | if .manifests | length != 1 then
177- error("expected only one manifests entry, not " + (.manifests | length))
178- else . end
179- | .manifests[0] |= (
180- if .mediaType != "application/vnd.oci.image.manifest.v1+json" then
181- error("unsupported descriptor mediaType: " + .mediaType)
182- else . end
183- | if .size < 0 then
184- error("invalid descriptor size: " + .size)
185- else . end
186- | del(.annotations, .urls)
187- | .annotations = {"org.opencontainers.image.source":"https://github.com/docker-library/busybox.git","org.opencontainers.image.revision":"7044abc7ee26712d998311b402b975124786e0cf","org.opencontainers.image.created":"2024-02-28T00:44:18Z","org.opencontainers.image.version":"1.36.1","org.opencontainers.image.url":"https://hub.docker.com/_/busybox","com.docker.official-images.bashbrew.arch":"arm32v5","org.opencontainers.image.base.name":"scratch"}
188- )
189- ' temp/index.json > temp/index.json.new
190- mv temp/index.json.new temp/index.json
191140# SBOM
192141originalImageManifest=" $( jq -r ' .manifests[0].digest' temp/index.json) "
193142SOURCE_DATE_EPOCH=1709081058 \
@@ -197,7 +146,7 @@ SOURCE_DATE_EPOCH=1709081058 \
197146 --build-arg BUILDKIT_DOCKERFILE_CHECK=skip=all \
198147 --sbom=generator=" $BASHBREW_BUILDKIT_SBOM_GENERATOR " \
199148 --output ' type=oci,tar=false,dest=sbom' \
200- --platform ' linux/arm/v5 ' \
149+ --platform ' linux/amd64 ' \
201150 --build-context " fake=oci-layout://$PWD /temp@$originalImageManifest " \
202151 - <<< ' FROM fake'
203152sbomIndex=" $( jq -r ' .manifests[0].digest' sbom/index.json) "
@@ -226,6 +175,6 @@ jq -r --argjson sbomManifestDesc "$sbomManifestDesc" '.manifests += [ $sbomManif
226175mv temp/index.json.new temp/index.json
227176# </build>
228177# <push>
229- crane push --index temp ' oisupport/staging-arm32v5:6dad189d12c5b50de48dab19c13869fdf25219dc430fc1d4c8a8dcc7bc893e69 '
178+ crane push --index temp ' oisupport/staging-amd64:191402ad0feacf03daf9d52a492207e73ef08b0bd17265043aea13aa27e2bb3f '
230179rm -rf temp
231180# </push>
0 commit comments