From e418680d728484b7dc5ed1a981bea8629de3bb86 Mon Sep 17 00:00:00 2001 From: Gabriel Roldan Date: Fri, 29 Dec 2023 15:21:04 -0300 Subject: [PATCH] Test build multiplatform images --- .github/workflows/build-and-push.yaml | 2 +- .github/workflows/pull-request.yaml | 29 ++++++++++++++++++++++++--- 2 files changed, 27 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-and-push.yaml b/.github/workflows/build-and-push.yaml index 53b92fa92..3486764f3 100644 --- a/.github/workflows/build-and-push.yaml +++ b/.github/workflows/build-and-push.yaml @@ -26,7 +26,7 @@ jobs: uses: sigstore/cosign-installer@v3.5.0 - name: Login to Docker Hub - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} diff --git a/.github/workflows/pull-request.yaml b/.github/workflows/pull-request.yaml index 2ff95bdac..a2fc81e42 100644 --- a/.github/workflows/pull-request.yaml +++ b/.github/workflows/pull-request.yaml @@ -32,6 +32,25 @@ jobs: java-version: '21' cache: 'maven' + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_HUB_USERNAME }} + password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} + + # Add support for more platforms with QEMU + # https://github.com/docker/setup-qemu-action + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + # https://github.com/docker/setup-buildx-action + with: + platforms: linux/amd64,linux/arm64 + # Sets up docker build command as an alias to docker buildx + install: true + - name: Validate source code formatting run: make lint @@ -39,14 +58,18 @@ jobs: run: | make install - - name: Test - run: | - make test +# - name: Test +# run: | +# make test - name: Build images run: | make build-image + #- name: Push images + # run: | + # make push-image + - name: Remove project jars from cached repository run: | rm -rf ~/.m2/repository/org/geoserver