]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Split building docker images to two separate workers. 16016/head
authorMarc Fehling <mafehling.git@gmail.com>
Wed, 20 Sep 2023 00:47:23 +0000 (18:47 -0600)
committerMarc Fehling <mafehling.git@gmail.com>
Wed, 20 Sep 2023 00:47:23 +0000 (18:47 -0600)
.github/workflows/docker.yml

index a236df96edc4b8caa35d8e7a48491e617e6cea55..55fd8b6e5b54ffa79dab67258cdf2549fd957e09 100644 (file)
@@ -12,7 +12,14 @@ permissions:
 
 jobs:
   build-master-docker:
+    name: build master docker ${{ matrix.ubuntu_version }}
     runs-on: ubuntu-latest
+
+    strategy:
+      fail-fast: false
+      matrix:
+        ubuntu_version: ["focal", "jammy"]
+
     steps:
       - name: Checkout code
         uses: actions/checkout@v4
@@ -26,26 +33,14 @@ jobs:
           username: ${{ secrets.DOCKER_USERNAME }}
           password: ${{ secrets.DOCKER_PASSWORD }}
 
-      - name: Build and push Docker image of master focal
-        uses: docker/build-push-action@v5
-        with:
-          context: ./contrib/docker/
-          cache-from: type=registry,ref=dealii/dependencies:focal
-          cache-to: type=inline
-          build-args: |
-            VER=master
-            IMG=focal
-          push: ${{github.ref_name == 'master'}}
-          tags: dealii/dealii:master-focal
-
-      - name: Build and push Docker image of master jammy
+      - name: Build and push Docker image of master ${{ matrix.ubuntu_version }}
         uses: docker/build-push-action@v5
         with:
           context: ./contrib/docker/
-          cache-from: type=registry,ref=dealii/dependencies:jammy
+          cache-from: type=registry,ref=dealii/dependencies:${{ matrix.ubuntu_version }}
           cache-to: type=inline
           build-args: |
             VER=master
-            IMG=jammy
+            IMG=${{ matrix.ubuntu_version }}
           push: ${{github.ref_name == 'master'}}
-          tags: dealii/dealii:master-jammy
+          tags: dealii/dealii:master-${{ matrix.ubuntu_version }}

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.