diff --git a/Dockerfile b/Dockerfile index 0bf4f5a..1f78315 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,5 @@ FROM alpine:3.20 -ENV KUBE_LATEST_VERSION="v1.28.0" -ENV TARGETARCH="amd64" - RUN apk add --update --no-cache curl jq \ && curl -L "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" -o /usr/local/bin/kubectl \ && chmod +x /usr/local/bin/kubectl diff --git a/Makefile b/Makefile index 440847d..4dc4007 100644 --- a/Makefile +++ b/Makefile @@ -6,8 +6,6 @@ BUILDER_NAME = k8s-wait-for-builder NON_ROOT_DOCKERFILE = DockerfileNonRoot DOCKER_TAGS = $(REPO_NAME):$(TAG_PREFIX)latest $(REPO_NAME):$(TAG_PREFIX)$(TAG) -all: push - images: image-root image-non-root image-root: image-root @@ -24,14 +22,11 @@ image-%: if ! docker buildx inspect $(BUILDER_NAME) 2> /dev/null ; then docker buildx create --name $(BUILDER_NAME) ; fi docker buildx build \ --builder=$(BUILDER_NAME) \ + --platform=linux/amd64 \ $(BUILD_FLAGS) \ $(foreach TAG,$(DOCKER_TAGS),--tag $(TAG)) \ . -push: BUILD_FLAGS := $(BUILD_FLAGS:--load=) -push: BUILD_FLAGS += --push -push: image-root image-non-root - clean: rm -f $(NON_ROOT_DOCKERFILE) if docker buildx inspect $(BUILDER_NAME) 2> /dev/null ; then docker buildx rm $(BUILDER_NAME) ; fi