Push fat manifest for multi-arch images

Signed-off-by: Nitesh Konkar <niteshkonkar@in.ibm.com>
This commit is contained in:
Nitesh Konkar 2018-05-08 21:00:34 +05:30
parent 678152bc00
commit ae23e19f20
2 changed files with 7 additions and 1 deletions

View File

@ -12,6 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
include ../../hack/make-rules/Makefile.manifest
REGISTRY ?= gcr.io/kubernetes-e2e-test-images
GOARM=7
QEMUVERSION=v2.9.1
@ -34,7 +36,7 @@ all: all-container
all-container:
./image-util.sh build $(WHAT)
all-push: all-container
all-push: all-container manifest-tool
./image-util.sh push $(WHAT)
.PHONY: all all-push all-container

View File

@ -99,6 +99,10 @@ push() {
TAG=$(<${IMAGE}/VERSION)
docker push ${REGISTRY}/${IMAGE}-${arch}:${TAG}
done
# Make archs list into OS/architecture pair. Eg: 'amd64 ppc64le' to 'linux/amd64,linux/ppc64le'
archs=$(echo $archs | sed -e 's/[^ ]* */linux\/&/g' -e 's/ /,/g')
manifest-tool push from-args --platforms ${archs} --template ${REGISTRY}/${IMAGE}-ARCH:${TAG} --target ${REGISTRY}/${IMAGE}:${TAG}
}
# This function is for building the go code