You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "tdiesler (via GitHub)" <gi...@apache.org> on 2024/03/15 12:43:52 UTC

[PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

tdiesler opened a new pull request, #5253:
URL: https://github.com/apache/camel-k/pull/5253

   To build all image variants, call
   
   ```
   make images-all
   ```
   
   Support push for `CUSTOM_IMAGE` (i.e. not just `STAGING_IMAGE`)


-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #5253:
URL: https://github.com/apache/camel-k/pull/5253#issuecomment-2003549399

   :heavy_check_mark: Unit test coverage report - coverage increased from 37.1% to 37.2% (**+0.1%**)


-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez merged PR #5253:
URL: https://github.com/apache/camel-k/pull/5253


-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

Posted by "tdiesler (via GitHub)" <gi...@apache.org>.
tdiesler commented on code in PR #5253:
URL: https://github.com/apache/camel-k/pull/5253#discussion_r1528244736


##########
script/Makefile:
##########
@@ -456,6 +456,18 @@ images-all:
 	make IMAGE_ARCH=arm64 images
 	make IMAGE_ARCH=amd64 images
 
+images-push:
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)
+	@if docker inspect $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 &> /dev/null; then \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 exists, building the multiarch manifest"; \
+		docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest create $(CUSTOM_IMAGE):$(CUSTOM_VERSION) --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64 --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest push --purge $(CUSTOM_IMAGE):$(CUSTOM_VERSION); \
+	else \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 does not exist"; \
+	fi
+
 images-push-staging:

Review Comment:
   No, this is intentional.
   
   The general idea is that `make images` (ignore the confusing plural) builds the image for your current platform. Hence, there is no guarantee that *-arm64 will be available.
   
   Only if you do `make images-all` will all the images be available - see the GHA for this
   
   `make images-push` should fail when *-amd64 is not available. In that way it is guaranteed, that the default version (without arch suffix) always points to: either the -amd64 variant or a manifest list that contains the -amd64 variant.
   
   



-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on code in PR #5253:
URL: https://github.com/apache/camel-k/pull/5253#discussion_r1526386217


##########
script/Makefile:
##########
@@ -456,6 +456,18 @@ images-all:
 	make IMAGE_ARCH=arm64 images
 	make IMAGE_ARCH=amd64 images
 
+images-push:
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)
+	@if docker inspect $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 &> /dev/null; then \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 exists, building the multiarch manifest"; \
+		docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest create $(CUSTOM_IMAGE):$(CUSTOM_VERSION) --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64 --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest push --purge $(CUSTOM_IMAGE):$(CUSTOM_VERSION); \
+	else \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 does not exist"; \
+	fi
+
 images-push-staging:

Review Comment:
   We need to remove this, then.



-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#5252] release-nightly does not build/push multiarch manifest [camel-k]

Posted by "tdiesler (via GitHub)" <gi...@apache.org>.
tdiesler commented on code in PR #5253:
URL: https://github.com/apache/camel-k/pull/5253#discussion_r1528244736


##########
script/Makefile:
##########
@@ -456,6 +456,18 @@ images-all:
 	make IMAGE_ARCH=arm64 images
 	make IMAGE_ARCH=amd64 images
 
+images-push:
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64
+	docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)
+	@if docker inspect $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 &> /dev/null; then \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 exists, building the multiarch manifest"; \
+		docker push $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest create $(CUSTOM_IMAGE):$(CUSTOM_VERSION) --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-amd64 --amend $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64; \
+		docker manifest push --purge $(CUSTOM_IMAGE):$(CUSTOM_VERSION); \
+	else \
+		echo "Image $(CUSTOM_IMAGE):$(CUSTOM_VERSION)-arm64 does not exist"; \
+	fi
+
 images-push-staging:

Review Comment:
   No, this is intentional.
   
   The general idea is that `make images` (ignore the confusing plural) builds the image for your current platform. Hence, there is no guarantee that *-arm64 will be available.
   
   Only if you do `make images-all` will all the images be available - see the GHA for this
   
   `make images-push` should fail when *-amd64 is not available. In this way it is guaranteed, that the default version (without arch suffix) always points to: either the -amd64 variant or a manifest list that contains the -amd64 variant.
   
   



-- 
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-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org