diff --git a/.github/workflows/.container.template.j2 b/.github/workflows/.container.template.j2 index 6128998..2c0f00f 100644 --- a/.github/workflows/.container.template.j2 +++ b/.github/workflows/.container.template.j2 @@ -52,15 +52,27 @@ jobs: run: | python -m pip install -r requirements.txt + <%- if multiarch %> + + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + + <%- endif %> + - name: "Generate Matrix Data" id: set-matrix run: | + <%- if multiarch %> + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=<{ exclude_platforms }> + <%- else %> inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + <%- endif %> mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}<%- if multiarch %>(${{ matrix.dockerinfo.arch }})<%- endif %>" strategy: fail-fast: false max-parallel: 4 @@ -117,19 +129,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" -<%- if multiarch %> - - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=<{ exclude_platforms }> source-container-inspect.txt -<%- endif %> - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -143,7 +142,7 @@ jobs: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} <%- if multiarch %> - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} <%- endif %> push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | diff --git a/.github/workflows/almalinux-containers.yml b/.github/workflows/almalinux-containers.yml index 4d43c6e..12b95af 100644 --- a/.github/workflows/almalinux-containers.yml +++ b/.github/workflows/almalinux-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/amazonlinux-containers.yml b/.github/workflows/amazonlinux-containers.yml index 81a339d..a226d00 100644 --- a/.github/workflows/amazonlinux-containers.yml +++ b/.github/workflows/amazonlinux-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/archlinux-containers.yml b/.github/workflows/archlinux-containers.yml index f316d33..260c9ef 100644 --- a/.github/workflows/archlinux-containers.yml +++ b/.github/workflows/archlinux-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/busybox-containers.yml b/.github/workflows/busybox-containers.yml index 662ef4f..84abd29 100644 --- a/.github/workflows/busybox-containers.yml +++ b/.github/workflows/busybox-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/centos-containers.yml b/.github/workflows/centos-containers.yml index ff5bae1..fcdda99 100644 --- a/.github/workflows/centos-containers.yml +++ b/.github/workflows/centos-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/centos-stream-containers.yml b/.github/workflows/centos-stream-containers.yml index 6c7868e..0a37df8 100644 --- a/.github/workflows/centos-stream-containers.yml +++ b/.github/workflows/centos-stream-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/consul-containers.yml b/.github/workflows/consul-containers.yml index 57ead67..0c0e67b 100644 --- a/.github/workflows/consul-containers.yml +++ b/.github/workflows/consul-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/debian-containers.yml b/.github/workflows/debian-containers.yml index 84e70d9..ad8c009 100644 --- a/.github/workflows/debian-containers.yml +++ b/.github/workflows/debian-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le,linux/ppc64le,linux/arm/v5 mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le,linux/ppc64le,linux/arm/v5 source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/etcd-v2-containers.yml b/.github/workflows/etcd-v2-containers.yml index 40cbdf3..a9bf3b3 100644 --- a/.github/workflows/etcd-v2-containers.yml +++ b/.github/workflows/etcd-v2-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/etcd-v3-containers.yml b/.github/workflows/etcd-v3-containers.yml index c04a609..9318cda 100644 --- a/.github/workflows/etcd-v3-containers.yml +++ b/.github/workflows/etcd-v3-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/fedora-containers.yml b/.github/workflows/fedora-containers.yml index 5c66f39..68c657d 100644 --- a/.github/workflows/fedora-containers.yml +++ b/.github/workflows/fedora-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/mariadb-containers.yml b/.github/workflows/mariadb-containers.yml index e53790b..e496774 100644 --- a/.github/workflows/mariadb-containers.yml +++ b/.github/workflows/mariadb-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/mysql-server-containers.yml b/.github/workflows/mysql-server-containers.yml index ef53a7e..560bd33 100644 --- a/.github/workflows/mysql-server-containers.yml +++ b/.github/workflows/mysql-server-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/openldap-minion-containers.yml b/.github/workflows/openldap-minion-containers.yml index d80fd39..5c82f51 100644 --- a/.github/workflows/openldap-minion-containers.yml +++ b/.github/workflows/openldap-minion-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/opensuse-containers.yml b/.github/workflows/opensuse-containers.yml index 110e1e4..1ba3123 100644 --- a/.github/workflows/opensuse-containers.yml +++ b/.github/workflows/opensuse-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/packaging-containers.yml b/.github/workflows/packaging-containers.yml index ccdda64..c4106a2 100644 --- a/.github/workflows/packaging-containers.yml +++ b/.github/workflows/packaging-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le,linux/386,linux/arm/v5,linux/arm/v7 mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le,linux/386,linux/arm/v5,linux/arm/v7 source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/percona-containers.yml b/.github/workflows/percona-containers.yml index a6bbab9..d333b67 100644 --- a/.github/workflows/percona-containers.yml +++ b/.github/workflows/percona-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/photon-containers.yml b/.github/workflows/photon-containers.yml index 76cf6b0..9e4a34f 100644 --- a/.github/workflows/photon-containers.yml +++ b/.github/workflows/photon-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le,linux/ppc64le,linux/arm/v5 mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le,linux/ppc64le,linux/arm/v5 source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/python-containers.yml b/.github/workflows/python-containers.yml index 8b4d3b1..978dad5 100644 --- a/.github/workflows/python-containers.yml +++ b/.github/workflows/python-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/rabbitmq-containers.yml b/.github/workflows/rabbitmq-containers.yml index 0861b94..ebff790 100644 --- a/.github/workflows/rabbitmq-containers.yml +++ b/.github/workflows/rabbitmq-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/redis-containers.yml b/.github/workflows/redis-containers.yml index 73edd62..08d4b13 100644 --- a/.github/workflows/redis-containers.yml +++ b/.github/workflows/redis-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/salt-containers.yml b/.github/workflows/salt-containers.yml index b25f5d1..11a6e77 100644 --- a/.github/workflows/salt-containers.yml +++ b/.github/workflows/salt-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/salt-gitfs-http-containers.yml b/.github/workflows/salt-gitfs-http-containers.yml index e0bbccc..23fa1cd 100644 --- a/.github/workflows/salt-gitfs-http-containers.yml +++ b/.github/workflows/salt-gitfs-http-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/ssh-minion-containers.yml b/.github/workflows/ssh-minion-containers.yml index 97c8fe8..80676de 100644 --- a/.github/workflows/ssh-minion-containers.yml +++ b/.github/workflows/ssh-minion-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/tinyproxy-containers.yml b/.github/workflows/tinyproxy-containers.yml index 5ed02be..e14cc93 100644 --- a/.github/workflows/tinyproxy-containers.yml +++ b/.github/workflows/tinyproxy-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/ubuntu-containers.yml b/.github/workflows/ubuntu-containers.yml index 1b22d7a..2f50129 100644 --- a/.github/workflows/ubuntu-containers.yml +++ b/.github/workflows/ubuntu-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/vault-containers.yml b/.github/workflows/vault-containers.yml index a87c4a6..523eaf4 100644 --- a/.github/workflows/vault-containers.yml +++ b/.github/workflows/vault-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/virt-minion-containers.yml b/.github/workflows/virt-minion-containers.yml index a070455..2902819 100644 --- a/.github/workflows/virt-minion-containers.yml +++ b/.github/workflows/virt-minion-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/.github/workflows/zookeeper-containers.yml b/.github/workflows/zookeeper-containers.yml index 7689737..6ef0bab 100644 --- a/.github/workflows/zookeeper-containers.yml +++ b/.github/workflows/zookeeper-containers.yml @@ -52,15 +52,19 @@ jobs: run: | python -m pip install -r requirements.txt + - name: "Docker BuildX" + id: buildx + uses: docker/setup-buildx-action@v2 + - name: "Generate Matrix Data" id: set-matrix run: | - inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} + inv containers.matrix --from-workflow ${{ env.PATH_IN_REPO }} --multiarch --exclude-arches=linux/s390x,linux/mips64le mirror-image: runs-on: ubuntu-latest needs: matrix-generator - name: "${{ matrix.dockerinfo.name }}" + name: "${{ matrix.dockerinfo.name }}(${{ matrix.dockerinfo.arch }})" strategy: fail-fast: false max-parallel: 4 @@ -117,16 +121,6 @@ jobs: echo "Flags: ${{ steps.buildx.outputs.flags }}" echo "Platforms: ${{ steps.buildx.outputs.platforms }}" - - name: Inspect Source Image - run: | - set -o pipefail - docker buildx imagetools inspect ${{ matrix.dockerinfo.source_container }} | tee -a source-container-inspect.txt - - - name: Define Build Platforms - id: define-platforms - run: | - inv containers.platforms --exclude=linux/s390x,linux/mips64le source-container-inspect.txt - - name: "Log into GitHub Container Registry" uses: docker/login-action@v2 with: @@ -139,7 +133,7 @@ jobs: with: file: ${{ matrix.dockerinfo.file }} context: ${{ env.PATH_IN_REPO }} - platforms: ${{ steps.define-platforms.outputs.platforms }} + platforms: ${{ matrix.dockerinfo.arch }} push: ${{ github.repository == 'saltstack/salt-ci-containers' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) }} tags: | ghcr.io/${{ github.repository }}/${{ matrix.dockerinfo.name }} diff --git a/tasks/containers.py b/tasks/containers.py index 457e31b..e9a4f47 100644 --- a/tasks/containers.py +++ b/tasks/containers.py @@ -173,13 +173,18 @@ def generate(ctx, ghcr_org="saltstack/salt-ci-containers"): @task -def matrix(ctx, image, from_workflow=False): +def matrix(ctx, image, from_workflow=False, multiarch=False, exclude_arches=None): """ Generate the container mirrors. """ ctx.cd(utils.REPO_ROOT) mirrors_path = utils.REPO_ROOT / image + if exclude_arches is None: + excludes = [] + else: + excludes = exclude_arches.split(",") + for name, details in _get_containers(): if details["path"] == image: break @@ -193,13 +198,30 @@ def matrix(ctx, image, from_workflow=False): source_container = f"{details['container']}:{source_tag}" else: source_container = _get_source_container(fpath) - output.append( - { - "name": f"{details['name']}:{fpath.stem}", - "file": str(fpath.relative_to(utils.REPO_ROOT)), - "source_container": source_container, - } - ) + + if multiarch: + ret = ctx.run(f"docker buildx imagetools inspect --raw {source_container}", echo=False) + data = json.loads(ret.stdout) + for entry in data.get("manifests"): + arch = entry["platform"]["architecture"] + if arch in excludes: + continue + output.append( + { + "name": f"{details['name']}:{fpath.stem}", + "arch": arch, + "file": str(fpath.relative_to(utils.REPO_ROOT)), + "source_container": source_container, + } + ) + else: + output.append( + { + "name": f"{details['name']}:{fpath.stem}", + "file": str(fpath.relative_to(utils.REPO_ROOT)), + "source_container": source_container, + } + ) utils.info("Generated Matrix:") utils.write_message(pprint.pformat(output))