1515 fail-fast : false
1616 matrix :
1717 ruby-version : [3.2, 3.3, 3.4, 3.5]
18- node-version : [20, 22]
18+ node-version : [20, 22, 24 ]
1919 variant : [default, slim, alpine]
2020 include :
2121 - variant : default
8383 echo "path=./${{ matrix.ruby-version }}/${{ matrix.node-version }}/${{ matrix.variant }}" >> $GITHUB_OUTPUT
8484 fi
8585
86+ - name : Set platforms
87+ id : platforms
88+ shell : bash
89+ run : |
90+ # For Node >=24, remove linux/arm/v7 from the variant's platform list
91+ BASE_PLATFORMS="${{ matrix.platforms }}"
92+ NODE_MAJOR="${{ matrix['node-version'] }}"
93+ if [ "$NODE_MAJOR" -ge 24 ]; then
94+ IFS=',' read -ra arr <<< "$BASE_PLATFORMS"
95+ out=()
96+ for p in "${arr[@]}"; do
97+ if [ "$p" != "linux/arm/v7" ] && [ -n "$p" ]; then
98+ out+=("$p")
99+ fi
100+ done
101+ (IFS=','; echo "platforms=${out[*]}") >> "$GITHUB_OUTPUT"
102+ else
103+ echo "platforms=$BASE_PLATFORMS" >> "$GITHUB_OUTPUT"
104+ fi
105+
86106 - name : Docker Buildx (build)
8710788108 if : success() && !contains(github.ref, 'master')
91111 context : ${{ steps.buildpath.outputs.path }}
92112 file : ${{ steps.buildpath.outputs.path }}/Dockerfile
93113 build-args : REFRESHED_AT=$(date +%Y-%m-%d)
94- platforms : ${{ matrix .platforms }}
114+ platforms : ${{ steps.platforms.outputs .platforms }}
95115 tags : ${{ steps.prepare.outputs.tags }}
96116
97117 - name : Docker Login
@@ -109,7 +129,7 @@ jobs:
109129 context : ${{ steps.buildpath.outputs.path }}
110130 file : ${{ steps.buildpath.outputs.path }}/Dockerfile
111131 build-args : REFRESHED_AT=$(date +%Y-%m-%d)
112- platforms : ${{ matrix .platforms }}
132+ platforms : ${{ steps.platforms.outputs .platforms }}
113133 tags : ${{ steps.prepare.outputs.tags }}
114134
115135 - name : Inspect Image
0 commit comments