From 98d4a3ed914cdb39c318aa84ad18b264af5beb50 Mon Sep 17 00:00:00 2001 From: jtkech Date: Thu, 7 Dec 2023 09:07:39 +0100 Subject: [PATCH 1/2] Docker Push in one Step --- .github/workflows/preview_ci.yml | 6 +----- .github/workflows/release_ci.yml | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/.github/workflows/preview_ci.yml b/.github/workflows/preview_ci.yml index f3ed27aeb0d..3bae88aacd0 100644 --- a/.github/workflows/preview_ci.yml +++ b/.github/workflows/preview_ci.yml @@ -62,7 +62,7 @@ jobs: with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PASSWORD }} - - name: Deploy preview docker image for linux + - name: Deploy preview docker image for linux and windows shell: pwsh if: matrix.os == 'ubuntu-latest' run: | @@ -72,9 +72,5 @@ jobs: dotnet publish -c Release --property:PublishDir=$output --no-build --framework net8.0 docker buildx build --load -f Dockerfile-CI --platform=linux/amd64 -t orchardproject/orchardcore-cms-linux:dev . docker push orchardproject/orchardcore-cms-linux:dev - - name: Deploy preview docker image for windows - shell: pwsh - if: matrix.os == 'ubuntu-latest' - run: | docker buildx build --load -f Dockerfile-CI --platform=windows/amd64 -t orchardproject/orchardcore-cms-windows:dev . docker push orchardproject/orchardcore-cms-windows:dev diff --git a/.github/workflows/release_ci.yml b/.github/workflows/release_ci.yml index 0781db1bca2..c24d1d3a597 100644 --- a/.github/workflows/release_ci.yml +++ b/.github/workflows/release_ci.yml @@ -73,7 +73,7 @@ jobs: with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PASSWORD }} - - name: Deploy release docker image for linux + - name: Deploy release docker image for linux and windows shell: pwsh if: matrix.os == 'ubuntu-latest' run: | @@ -84,10 +84,6 @@ jobs: docker buildx build --load -f Dockerfile-CI --platform=linux/amd64 -t orchardproject/orchardcore-cms-linux:latest -t orchardproject/orchardcore-cms-linux:${{ steps.get_version.outputs.VERSION }} . docker push orchardproject/orchardcore-cms-linux:latest docker push "orchardproject/orchardcore-cms-linux:${{ steps.get_version.outputs.VERSION }}" - - name: Deploy release docker image for windows - shell: pwsh - if: matrix.os == 'ubuntu-latest' - run: | docker buildx build --load -f Dockerfile-CI --platform=windows/amd64 -t orchardproject/orchardcore-cms-windows:latest -t orchardproject/orchardcore-cms-windows:${{ steps.get_version.outputs.VERSION }} . docker push orchardproject/orchardcore-cms-windows:latest docker push "orchardproject/orchardcore-cms-windows:${{ steps.get_version.outputs.VERSION }}" From 18013d722ad92e52aa654c0c4c93d18f8529041b Mon Sep 17 00:00:00 2001 From: jtkech Date: Thu, 7 Dec 2023 09:10:14 +0100 Subject: [PATCH 2/2] Update Docker Login --- .github/workflows/preview_ci.yml | 2 +- .github/workflows/release_ci.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/preview_ci.yml b/.github/workflows/preview_ci.yml index 3bae88aacd0..58da8080669 100644 --- a/.github/workflows/preview_ci.yml +++ b/.github/workflows/preview_ci.yml @@ -58,7 +58,7 @@ jobs: uses: docker/setup-buildx-action@v3 - name: Login to DockerHub if: matrix.os == 'ubuntu-latest' - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PASSWORD }} diff --git a/.github/workflows/release_ci.yml b/.github/workflows/release_ci.yml index c24d1d3a597..d28bc4d6695 100644 --- a/.github/workflows/release_ci.yml +++ b/.github/workflows/release_ci.yml @@ -69,7 +69,7 @@ jobs: uses: docker/setup-buildx-action@v3 - name: Login to DockerHub if: matrix.os == 'ubuntu-latest' - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PASSWORD }}