tdiesler commented on code in PR #5200: URL: https://github.com/apache/camel-k/pull/5200#discussion_r1519759320
########## script/Makefile: ########## @@ -424,57 +433,36 @@ maven-overlay: mkdir -p build/_maven_overlay ./script/maven_overlay.sh build/_maven_overlay -kamel-overlay: - mkdir -p build/_output/bin -ifeq ($(shell uname -s 2>/dev/null || echo Unknown),Linux) - @echo "####### Copying Linux platform arch $(IMAGE_ARCH) CLI into output build directory..." -else - @echo "####### (Re)Building a Linux platform arch $(IMAGE_ARCH) CLI " - @echo "####### Likely you're on a non Linux host, so I need to build a Linux CLI to bundle in the container image" - GOOS=linux GOARCH=$(IMAGE_ARCH) go build $(GOFLAGS) -o build/_output/bin/kamel-$(IMAGE_ARCH) ./cmd/kamel/*.go -endif - cp build/_output/bin/kamel-$(IMAGE_ARCH) build/_output/bin/kamel - TARGET_STAGE := base ifeq ($(DEBUG_MODE),true) TARGET_STAGE := debug CUSTOM_IMAGE := $(CUSTOM_IMAGE)-debug endif -DOCKER_TAG := $(CUSTOM_IMAGE):$(CUSTOM_VERSION) -ifneq ($(IMAGE_ARCH), amd64) - DOCKER_TAG := $(DOCKER_TAG)-$(IMAGE_ARCH) -endif - -images: build kamel-overlay maven-overlay bundle-kamelets +package_maven_artifacts: ifneq (,$(findstring SNAPSHOT,$(DEFAULT_RUNTIME_VERSION))) ./script/package_maven_artifacts.sh -s "$(STAGING_RUNTIME_REPO)" -d "$(CAMEL_K_RUNTIME_DIR)" $(DEFAULT_RUNTIME_VERSION) endif - @echo "####### Building Camel K operator arch $(IMAGE_ARCH) container image..." - mkdir -p build/_maven_output - docker buildx build --target $(TARGET_STAGE) --platform=linux/$(IMAGE_ARCH) -t $(DOCKER_TAG) -f build/Dockerfile . -# Mainly used for internal CI purposes Review Comment: I you now run ``` make images ``` you get the image for your platform. Images for alternative platforms can be built as before e.g. ``` make IMAGE_ARCH=arm64 images ``` Push works with and without `arm64`. We only create/push the manifest list when images for both platforms are already available -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org