You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by sh...@apache.org on 2021/05/28 13:16:07 UTC

[apisix-docker] branch master updated: ci: change new release trigger from release to release branch (#178)

This is an automated email from the ASF dual-hosted git repository.

shuyangw 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 9d2b2f8  ci: change new release trigger from release to release branch (#178)
9d2b2f8 is described below

commit 9d2b2f8104d5b709e54d9141c0ae8fe6b8678bc7
Author: Shuyang Wu <wo...@gmail.com>
AuthorDate: Fri May 28 09:16:02 2021 -0400

    ci: change new release trigger from release to release branch (#178)
    
    Co-authored-by: Alex Zhang <to...@apache.org>
---
 .github/workflows/apisix_push_docker_hub.yaml    | 4 ++--
 .github/workflows/dashboard_push_docker_hub.yaml | 4 ++--
 MAINTAINING.md                                   | 5 +++++
 Makefile                                         | 6 +++++-
 4 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/.github/workflows/apisix_push_docker_hub.yaml b/.github/workflows/apisix_push_docker_hub.yaml
index abf3b6c..faa5925 100644
--- a/.github/workflows/apisix_push_docker_hub.yaml
+++ b/.github/workflows/apisix_push_docker_hub.yaml
@@ -1,7 +1,7 @@
 name: Push apisix to Docker image
 on:
-  release:
-    types: [ published ]
+  push:
+    branches: ['release/apisix-**']
 jobs:
   build:
     runs-on: ubuntu-latest
diff --git a/.github/workflows/dashboard_push_docker_hub.yaml b/.github/workflows/dashboard_push_docker_hub.yaml
index 9db5c52..87d2a0c 100644
--- a/.github/workflows/dashboard_push_docker_hub.yaml
+++ b/.github/workflows/dashboard_push_docker_hub.yaml
@@ -1,7 +1,7 @@
 name: Push apisix dashboard to Docker image
 on:
-  release:
-    types: [ published ]
+  push:
+    branches: ['release/dashboard**']
 jobs:
   build:
     runs-on: ubuntu-latest
diff --git a/MAINTAINING.md b/MAINTAINING.md
new file mode 100644
index 0000000..547868c
--- /dev/null
+++ b/MAINTAINING.md
@@ -0,0 +1,5 @@
+## New release
+
+To make and publish new docker images on docker hub, maintainers should create branch under `apisix-docker` repo with specific name.
+
+For apisix and dashboard new version, the branch name should use prefix `release/apisix` and `release/dashboard` separately (e.g. `release/apisix-2.6`, `release/dashboard-2.6`). Remember to delete the release branch after the new images published, since the branch would got no use afterwards.
diff --git a/Makefile b/Makefile
index edbc0df..e5729f9 100644
--- a/Makefile
+++ b/Makefile
@@ -36,11 +36,13 @@ build-on-alpine:
 # Actually it is not build on certain version but on local code
 # Use this name (in the same patterns with others) for convenient CI
 build-on-alpine-local:
-	docker build -t $(IMAGE_NAME):$(APISIX_VERSION)-alpine-local --build-arg APISIX_PATH=${APISIX_PATH} -f ./alpine-local/Dockerfile .	
+	docker build -t $(IMAGE_NAME):$(APISIX_VERSION)-alpine-local --build-arg APISIX_PATH=${APISIX_PATH} -f ./alpine-local/Dockerfile .
 
 ### push-on-centos:       Push apache/apisix:xx-centos image
 push-on-centos:
 	docker push $(IMAGE_NAME):$(APISIX_VERSION)-centos
+	docker build -t $(IMAGE_NAME):latest -f ./centos/Dockerfile .
+	docker push $(IMAGE_NAME):latest
 
 ### push-on-alpine:       Push apache/apisix:xx-alpine image
 push-on-alpine:
@@ -71,6 +73,8 @@ build-dashboard:
 ### push-dashboard:     Push apache/dashboard:tag image
 push-dashboard:
 	docker push $(APISIX_DASHBOARD_IMAGE_NAME):$(APISIX_DASHBOARD_VERSION)
+	docker build -t $(APISIX_DASHBOARD_IMAGE_NAME):latest -f ./dashboard/Dockerfile .
+	docker push $(APISIX_DASHBOARD_IMAGE_NAME):latest
 
 ### save-dashboard-tar:      tar apache/apisix-dashboard:tag image
 save-dashboard-tar: