Test images before pushing
authorPablo Zmdl <redacted>
Wed, 4 Jun 2025 10:47:48 +0000 (12:47 +0200)
committerPablo Zmdl <redacted>
Wed, 11 Jun 2025 12:41:37 +0000 (14:41 +0200)
Currently they are pushed before they are tested, which is not really
sensible.

.github/workflows/build-and-publish-nightly.yml
.github/workflows/build.yml

index f40b98a54099a1e830bb4237d2f06784e272a710..056674fee8a6beb250a525cbabf0e78b89a11428 100644 (file)
@@ -32,12 +32,11 @@ jobs:
         with:
           buildkitd-flags: --debug
 
-      - name: Build and push nightly image"
+      - name: Build nightly image for tests"
         uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
         with:
           context: nightly
-          platforms: "linux/arm64,linux/arm/v6,linux/arm/v7,linux/386,linux/amd64,"
-          push: true
+          load: true
           tags: roundcube/roundcubemail:nightly
           cache-from: type=gha
           cache-to: type=gha,mode=max
@@ -47,3 +46,11 @@ jobs:
         env:
           ROUNDCUBEMAIL_TEST_IMAGE: roundcube/roundcubemail:nightly
         run: docker compose -f ./tests/docker-compose.test-apache-postgres.yml up --exit-code-from=sut --abort-on-container-exit
+
+      - name: Build and push nightly images for all platforms
+        uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
+        with:
+          context: nightly
+          platforms: "linux/arm64,linux/arm/v6,linux/arm/v7,linux/386,linux/amd64"
+          push: true
+          tags: roundcube/roundcubemail:nightly
index b62c87be79487a2b61ed15aa51a87ab8b0a855c0..e305b4c2b6615b20e10d2ed081540dc82d2cbfca 100644 (file)
@@ -89,8 +89,7 @@ jobs:
         uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
         with:
           context: ${{ matrix.variant }}
-          platforms: "linux/arm64,linux/arm/v6,linux/arm/v7,linux/386,linux/amd64,"
-          push: true
+          load: true
           tags: ${{ matrix.docker-tag }}
           target: ${{ matrix.target }}
           cache-from: type=gha
@@ -108,3 +107,12 @@ jobs:
             docker compose -f ./tests/docker-compose.test-${testFile}.yml \
             up --exit-code-from=sut --abort-on-container-exit
           done
+
+      - name: Build and push images for "${{ matrix.variant }} for all platforms"
+        uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
+        with:
+          context: ${{ matrix.variant }}
+          platforms: "linux/arm64,linux/arm/v6,linux/arm/v7,linux/386,linux/amd64,"
+          push: true
+          tags: ${{ matrix.docker-tag }}
+          target: ${{ matrix.target }}
git clone https://git.99rst.org/PROJECT