Skip to content

Commit b9cfca0

Browse files
committed
apps: Set variant explicitly for arm and arm64
Set the `--variant` parameter value explicitly in the `docker manifest annotate` command, otherwise it may choose an incorrect variant type. Signed-off-by: Mike Sul <mike.sul@foundries.io>
1 parent 4b70095 commit b9cfca0

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

apps/build.sh

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,13 +192,19 @@ for x in $IMAGES ; do
192192
for t in $(eval echo "\$$var") ; do
193193
status "Handling manifest logic for $var"
194194

195+
variant=""
196+
if [ "${t}" = "arm64" ]; then
197+
variant="--variant v8"
198+
elif [ "${t}" = "arm" ]; then
199+
variant="--variant v7"
200+
fi
195201
tmp=$HOME/.docker/manifests/${hub_fio}_${FACTORY}_${x}-${H_BUILD}_${TAG}
196202
cp ${tmp}/${hub_fio}_${FACTORY}_${x}-${TAG}-${ARCH} ${tmp}/${hub_fio}_${FACTORY}_${x}-${TAG}-${t}
197-
run docker manifest annotate ${ct_base}:${H_BUILD}_${TAG} ${ct_base}:${TAG}-$t --arch $t
203+
run docker manifest annotate ${ct_base}:${H_BUILD}_${TAG} ${ct_base}:${TAG}-$t --arch $t "${variant}"
198204

199205
tmp=$HOME/.docker/manifests/${hub_fio}_${FACTORY}_${x}-${LATEST}
200206
cp ${tmp}/${hub_fio}_${FACTORY}_${x}-${TAG}-${ARCH} ${tmp}/${hub_fio}_${FACTORY}_${x}-${TAG}-${t}
201-
run docker manifest annotate ${ct_base}:${LATEST} ${ct_base}:${TAG}-$t --arch $t
207+
run docker manifest annotate ${ct_base}:${LATEST} ${ct_base}:${TAG}-$t --arch $t "${variant}"
202208
done
203209

204210
echo "Build step $((completed+2)) of $total is complete"

0 commit comments

Comments
 (0)