You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by sp...@apache.org on 2022/09/04 12:09:54 UTC
[apisix-docker] branch master updated: feat: support publish multiarch centos (#346)
This is an automated email from the ASF dual-hosted git repository.
spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-docker.git
The following commit(s) were added to refs/heads/master by this push:
new 8fcde17 feat: support publish multiarch centos (#346)
8fcde17 is described below
commit 8fcde17495985f9187e9be46f9daa41275b7c012
Author: soulbird <zh...@outlook.com>
AuthorDate: Sun Sep 4 20:09:49 2022 +0800
feat: support publish multiarch centos (#346)
Co-authored-by: soulbird <zh...@gmail.com>
---
.github/workflows/apisix_push_docker_hub.yaml | 4 ++--
Makefile | 33 ++++++++++++++++++---------
2 files changed, 24 insertions(+), 13 deletions(-)
diff --git a/.github/workflows/apisix_push_docker_hub.yaml b/.github/workflows/apisix_push_docker_hub.yaml
index 35bea7a..e9e5f84 100644
--- a/.github/workflows/apisix_push_docker_hub.yaml
+++ b/.github/workflows/apisix_push_docker_hub.yaml
@@ -26,5 +26,5 @@ jobs:
run: |
make push-multiarch-on-debian
make push-multiarch-on-alpine
- make build-on-centos
- make push-on-centos
+ make push-multiarch-on-centos
+ make push-multiarch-on-latest
diff --git a/Makefile b/Makefile
index b1f3e5a..a4b0f9f 100644
--- a/Makefile
+++ b/Makefile
@@ -92,17 +92,6 @@ build-on-debian:
@$(call func_echo_success_status, "$@ -> [ Done ]")
-### push-on-centos : Push apache/apisix:xx-centos image
-# centos not support multiarch since it reply on x86 rpm package
-.PHONY: push-on-centos
-push-on-centos:
- @$(call func_echo_status, "$@ -> [ Start ]")
- $(ENV_DOCKER) push $(ENV_APISIX_IMAGE_TAG_NAME)-centos
- $(ENV_DOCKER) build -t $(IMAGE_NAME):latest -f ./centos/Dockerfile .
- $(ENV_DOCKER) push $(IMAGE_NAME):latest
- @$(call func_echo_success_status, "$@ -> [ Done ]")
-
-
### push-on-alpine : Push apache/apisix:xx-alpine image
.PHONY: push-multiarch-on-alpine
push-multiarch-on-alpine:
@@ -136,6 +125,28 @@ push-multiarch-on-debian:
@$(call func_echo_success_status, "$@ -> [ Done ]")
+### push-multiarch-on-centos : Push apache/apisix:xx-centos image
+.PHONY: push-multiarch-on-centos
+push-multiarch-on-centos:
+ @$(call func_echo_status, "$@ -> [ Start ]")
+ $(ENV_DOCKER) buildx build --network=host --push \
+ -t $(ENV_APISIX_IMAGE_TAG_NAME)-centos \
+ --platform linux/amd64,linux/arm64 \
+ -f ./centos/Dockerfile .
+ @$(call func_echo_success_status, "$@ -> [ Done ]")
+
+
+### push-multiarch-on-latest : Push apache/apisix:latest image
+.PHONY: push-multiarch-on-latest
+push-multiarch-on-latest:
+ @$(call func_echo_status, "$@ -> [ Start ]")
+ $(ENV_DOCKER) buildx build --network=host --push \
+ -t $(IMAGE_NAME):latest \
+ --platform linux/amd64,linux/arm64 \
+ -f ./debian/Dockerfile .
+ @$(call func_echo_success_status, "$@ -> [ Done ]")
+
+
### build-on-alpine-cn : Build apache/apisix:xx-alpine image (for chinese)
.PHONY: build-on-alpine-cn
build-on-alpine-cn: