From bc262d6e85341170b554b366dbbde6b0b9fed31b Mon Sep 17 00:00:00 2001 From: hasheddan Date: Wed, 13 Jan 2021 08:46:01 -0600 Subject: [PATCH 1/2] Specify BASEIMAGE platform for conformance image Updates conformance image Dockerfile to specify platform for BASEIMAGE and sets correct ARCH in Makefile. Signed-off-by: hasheddan --- cluster/images/conformance/Dockerfile | 2 +- cluster/images/conformance/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cluster/images/conformance/Dockerfile b/cluster/images/conformance/Dockerfile index 2466bbace45..0fc607f994b 100644 --- a/cluster/images/conformance/Dockerfile +++ b/cluster/images/conformance/Dockerfile @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM BASEIMAGE +FROM --platform=linux/ARCH BASEIMAGE COPY ginkgo /usr/local/bin/ COPY e2e.test /usr/local/bin/ diff --git a/cluster/images/conformance/Makefile b/cluster/images/conformance/Makefile index 76bb6f10db2..2764869dcce 100644 --- a/cluster/images/conformance/Makefile +++ b/cluster/images/conformance/Makefile @@ -54,7 +54,7 @@ endif chmod a+rx ${TEMP_DIR}/e2e.test chmod a+rx ${TEMP_DIR}/gorunner - cd ${TEMP_DIR} && sed -i.back "s|BASEIMAGE|${BASEIMAGE}|g" Dockerfile + cd ${TEMP_DIR} && sed -i.back "s|ARCH|${ARCH}|g; s|BASEIMAGE|${BASEIMAGE}|g" Dockerfile docker build --pull -t ${REGISTRY}/conformance-${ARCH}:${VERSION} ${TEMP_DIR} rm -rf "${TEMP_DIR}" From baccf02ab07773e3518577c81becc1486cef33d3 Mon Sep 17 00:00:00 2001 From: hasheddan Date: Wed, 13 Jan 2021 08:49:27 -0600 Subject: [PATCH 2/2] Switch to debian:stable-slim for conformance image base The currently used debian:stretch-slim does not support s390x arch in its multi-arch build. We opt to use stable-slim instead of pulling in different base images for each platform build. Signed-off-by: hasheddan --- cluster/images/conformance/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cluster/images/conformance/Makefile b/cluster/images/conformance/Makefile index 2764869dcce..c2284d1fb12 100644 --- a/cluster/images/conformance/Makefile +++ b/cluster/images/conformance/Makefile @@ -31,7 +31,7 @@ E2E_GO_RUNNER_BIN?=$(shell test -f $(LOCAL_OUTPUT_PATH)/go-runner && echo $(LOCA CLUSTER_DIR?=$(shell pwd)/../../../cluster/ -BASEIMAGE=debian:stretch-slim +BASEIMAGE=debian:stable-slim TEMP_DIR:=$(shell mktemp -d -t conformanceXXXXXX) all: build