Clean up BASEIMAGE handling

master
Tim Hockin 2019-01-28 11:41:28 -08:00
parent d5b61a98de
commit f1f13cf64f
1 changed files with 6 additions and 7 deletions

View File

@ -41,17 +41,16 @@ ARCH := $(if $(GOARCH),$(GOARCH),$(shell go env GOARCH))
# Set default base image dynamically for each arch
# TODO: make these all consistent and tagged.
ifeq ($(ARCH),amd64)
ifeq ($(OS)/$(ARCH),linux/amd64)
BASEIMAGE ?= alpine:3.8
endif
ifeq ($(ARCH),arm)
else ifeq ($(OS)/$(ARCH),linux/arm)
BASEIMAGE ?= armel/busybox
endif
ifeq ($(ARCH),arm64)
else ifeq ($(OS)/$(ARCH),linux/arm64)
BASEIMAGE ?= aarch64/busybox
endif
ifeq ($(ARCH),ppc64le)
else ifeq ($(OS)/$(ARCH),linux/ppc64le)
BASEIMAGE ?= ppc64le/busybox
else
$(error Unsupported target platform '$(OS)/$(ARCH)')
endif
IMAGE := $(REGISTRY)/$(BIN)