From 8d6a600caf9740a7effd70e9c8c1dc73fd61382e Mon Sep 17 00:00:00 2001 From: Mike Maietta Date: Sun, 19 Jan 2025 16:41:08 -0800 Subject: [PATCH] fix: docker deploy script runs out of space on single runner (#8788) --- .github/workflows/deploy-docker.yml | 40 ++++++++--------------------- docker/node/Dockerfile | 2 +- 2 files changed, 12 insertions(+), 30 deletions(-) diff --git a/.github/workflows/deploy-docker.yml b/.github/workflows/deploy-docker.yml index d888cad13c2..4846d1d1b6f 100644 --- a/.github/workflows/deploy-docker.yml +++ b/.github/workflows/deploy-docker.yml @@ -24,42 +24,24 @@ jobs: name: Build and Push Docker needs: run-docker-build-and-test runs-on: ubuntu-latest - + strategy: + fail-fast: true + matrix: + nodeMajorVersion: [ + 14, 16, 18, 20, 22 + ] steps: - - name: Download images artifact - node14 - uses: actions/download-artifact@v4 - with: - name: electron-builder-all-14 - path: ${{ runner.temp }} - - - name: Download images artifact - node16 - uses: actions/download-artifact@v4 - with: - name: electron-builder-all-16 - path: ${{ runner.temp }} - - - name: Download images artifact - node18 - uses: actions/download-artifact@v4 - with: - name: electron-builder-all-18 - path: ${{ runner.temp }} - - - name: Download images artifact - node20 - uses: actions/download-artifact@v4 - with: - name: electron-builder-all-20 - path: ${{ runner.temp }} - - - name: Download images artifact - node22 + - name: Download images artifact - node${{ matrix.nodeMajorVersion }} uses: actions/download-artifact@v4 with: - name: electron-builder-all-22 + name: electron-builder-all-${{ matrix.nodeMajorVersion }} path: ${{ runner.temp }} - name: Load all images - run: find ${{ runner.temp }} -type f -name "electron-builder-all-*.tar" -exec docker image load --input "{}" \; + run: docker image load --input ${{ runner.temp }}/electron-builder-all-${{ matrix.nodeMajorVersion }}.tar - - name: Tag LTS images for electron-builder latest/wine/wine-chrome/wine-mono + - name: Tag LTS (${{ env.LATEST_IMAGE_NODE_MAJOR_VERSION }}) images for electron-builder latest/wine/wine-chrome/wine-mono + if: ${{ matrix.nodeMajorVersion == env.LATEST_IMAGE_NODE_MAJOR_VERSION }} run: | docker image tag electronuserland/builder:${{ env.LATEST_IMAGE_NODE_MAJOR_VERSION }} electronuserland/builder:latest docker image tag electronuserland/builder:${{ env.LATEST_IMAGE_NODE_MAJOR_VERSION }}-wine electronuserland/builder:wine diff --git a/docker/node/Dockerfile b/docker/node/Dockerfile index 1827e54dd2f..e75f25b0e41 100644 --- a/docker/node/Dockerfile +++ b/docker/node/Dockerfile @@ -1,7 +1,7 @@ ARG IMAGE_VERSION=base FROM --platform=linux/x86_64 electronuserland/builder:$IMAGE_VERSION -ARG NODE_VERSION=22.13.0 +ARG NODE_VERSION # this package is used for snapcraft and we should not clear apt list - to avoid apt-get update during snap build RUN curl -L https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-x64.tar.gz | tar xz -C /usr/local --strip-components=1 && \