-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
create_multi.sh
executable file
·36 lines (33 loc) · 1.37 KB
/
create_multi.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/usr/bin/env bash
###############################################################
#
# Copyright (C) 2023 James Fuller, <[email protected]>, et al.
#
# SPDX-License-Identifier: curl-container
###############################################################
#
# Create a multi arch image
# ex.
# > create_multi.sh {
#
# get invoke opts
base=${1}
compiler=${2}
dev_deps=${3}
base_deps=${4}
build_opts=${5}
branch_or_ref=${6}
release_tag=${7}
echo "####### creating curl multi image."
buildah manifest create curl-base-multi:${release_tag}
buildah manifest create curl-multi:${release_tag}
# loop through supported arches
for IMGTAG in "linux/386" "linux/arm/v7" "linux/amd64" "linux/arm64" "linux/ppc64le" ; do
pathname="${IMGTAG////-}"
echo "building $IMGTAG : $pathname"
./create_dev_image.sh "$IMGTAG" ${base} ${compiler} "$dev_deps" "$build_opts" ${branch_or_ref} curl-dev-${pathname}:${release_tag} 0
./create_base_image.sh "$IMGTAG" ${base} localhost/curl-dev-${pathname}:${release_tag} "$base_deps" curl-base-${pathname}:${release_tag} ${release_tag}
buildah manifest add curl-base-multi:${release_tag} localhost/curl-base-${pathname}:${release_tag};
./create_appliance_image.sh "$IMGTAG" localhost/curl-base-${pathname}:${release_tag} curl-${pathname}:${release_tag} ${release_tag}
buildah manifest add curl-multi:${release_tag} localhost/curl-${pathname}:${release_tag};
done