From 0b7fb25f73211cb8a366535882da282e3982f25a Mon Sep 17 00:00:00 2001 From: Ernst Noorlander Date: Sat, 13 Apr 2024 14:46:05 +0200 Subject: [PATCH] Other version of docker-deploy --- .github/workflows/docker-deploy.yml | 47 ++++++++++++++--------------- 1 file changed, 23 insertions(+), 24 deletions(-) diff --git a/.github/workflows/docker-deploy.yml b/.github/workflows/docker-deploy.yml index 50965b4..c7f0113 100644 --- a/.github/workflows/docker-deploy.yml +++ b/.github/workflows/docker-deploy.yml @@ -4,31 +4,30 @@ on: push: branches: - main - + jobs: - build-and-push: + docker: runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Log in to Docker Hub - uses: docker/login-action@v1 - with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} - - - name: Build and push Docker image - uses: docker/build-push-action@v2 - with: - push: true - tags: ictu/zap2docker-weekly:latest + - name: Checkout + uses: actions/checkout@v4 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - name: Build + uses: docker/build-push-action@v5 + with: + context: . + platforms: linux/amd64,linux/arm64 + tags: ictu/zap2docker-weekly:latest + secrets: | + "github_token=${{ secrets.DOCKERHUB_TOKEN }}" - - name: Update README on Docker Hub - uses: peter-evans/dockerhub-description@v2 - env: - DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} - DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }} - DOCKERHUB_REPOSITORY: ictu/zap2docker-weekly - README_FILEPATH: ./README.md + - name: Update README on Docker Hub + uses: peter-evans/dockerhub-description@v2 + env: + DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} + DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }} + DOCKERHUB_REPOSITORY: ictu/zap2docker-weekly + README_FILEPATH: ./README.md \ No newline at end of file