From ea93a958e862e1cff18fa15de6ee0211cba2bcce Mon Sep 17 00:00:00 2001 From: Alexandre DEVELY <12896316+alexandredevely@users.noreply.github.com> Date: Thu, 28 Nov 2024 14:11:02 +0100 Subject: [PATCH 1/4] add branch checkout --- .github/workflows/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6e24732..d429c2f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -23,6 +23,8 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v4 + with: + ref: ${{ env.branch }} - name: Set up QEMU uses: docker/setup-qemu-action@v3 From f5d2298fbe3919ad4addb7918e20d3dbb109699d Mon Sep 17 00:00:00 2001 From: Alexandre DEVELY <12896316+alexandredevely@users.noreply.github.com> Date: Thu, 28 Nov 2024 14:22:11 +0100 Subject: [PATCH 2/4] Update main.yml --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d429c2f..45bbbd0 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -46,7 +46,7 @@ jobs: with: file: Dockerfile context: . - platforms: linux/amd64,linux/arm64 + platforms: linux/amd64 push: true build-args: | BASE_IMAGE_RELEASE=latest From e54cb134764b3e3ce045e0e801a2062659e480c9 Mon Sep 17 00:00:00 2001 From: Alexandre DEVELY <12896316+alexandredevely@users.noreply.github.com> Date: Thu, 28 Nov 2024 14:26:21 +0100 Subject: [PATCH 3/4] Update main.yml --- .github/workflows/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 45bbbd0..eb95ea4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -25,6 +25,7 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ env.branch }} + fetch-depth: 0 - name: Set up QEMU uses: docker/setup-qemu-action@v3 From 6729a2e12bfe5021e76101c9f9b151e591ecd458 Mon Sep 17 00:00:00 2001 From: Alexandre DEVELY <12896316+alexandredevely@users.noreply.github.com> Date: Thu, 28 Nov 2024 17:47:41 +0100 Subject: [PATCH 4/4] add builder --- .github/workflows/main.yml | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index eb95ea4..d0bd08f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -45,7 +45,7 @@ jobs: - name: Build and push builder image uses: docker/build-push-action@v5 with: - file: Dockerfile + file: Dockerfile.builder context: . platforms: linux/amd64 push: true @@ -54,5 +54,22 @@ jobs: BASE_IMAGE=ubuntu BRANCH=${{ env.branch }} NODE_MAJOR=${{ env.node_version }} + tags: | + abcdesktopio/oc.nginx.builder:${{ env.imagetag }} + + - name: Build and push oc.nginx image + uses: docker/build-push-action@v5 + with: + file: Dockerfile + context: . + platforms: linux/amd64 + push: true + build-args: | + BASE_IMAGE_RELEASE=${{ env.imagetag }} + BASE_IMAGE=abcdesktopio/oc.nginx.builder + BRANCH=${{ env.branch }} + TARGET=dev + NODE_MAJOR=${{ env.node_version }} tags: | abcdesktopio/oc.nginx:${{ env.imagetag }} +